There would be a written contract between the two companies outlining Tesla's responsibilities. If this case proceeds that far, it would definitely be part of the evidentiary record.
Fairly hard to invent seven roof fires in retail premises and Tesla's first act when they took over Solar City was to massacre the sales department. That means that things had got so bad in there that taking money from new customers was not worth the risk, given the product.
Failure due to rushed, shoddy work is definitely Tesla's M.O., but Walmart is also not exactly the most credible source, given their history.