laravel/framework — pull request #1005 by JeffreyWay (2013-04-19 04:37:42+00:00)
Title: Provide better assertion feedback for missing view

If you assert that a view has a variable, but a View instance hasn't yet been returned, then a nasty fatal error will be displayed.

```bash
.PHP Fatal error: Call to a member function getData() on a non-object
```

This doesn't really help when following a TDD process. This commit simply checks whether the getData method exists. If it doesn't, then it provides more actionable feedback.

```bash
1) ExampleTest::testAssignsOrdersToView
A view has not yet been loaded.
```