File tree Expand file tree Collapse file tree 1 file changed +16
-2
lines changed
tests/Integration/CachedBuilder Expand file tree Collapse file tree 1 file changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -19,13 +19,27 @@ class FirstTest extends IntegrationTestCase
1919{
2020 public function testFirstReturnsAllAttributesForModel ()
2121 {
22- $ author = (new Author )->where ("id " , "= " , 1 )->first ();
23- $ uncachedAuthor = (new UncachedAuthor )->where ("id " , "= " , 1 )->first ();
22+ $ author = (new Author )
23+ ->where ("id " , "= " , 1 )
24+ ->first ();
25+ $ uncachedAuthor = (new UncachedAuthor )
26+ ->where ("id " , "= " , 1 )
27+ ->first ();
2428
2529 $ this ->assertEquals ($ author ->id , $ uncachedAuthor ->id );
2630 $ this ->assertEquals ($ author ->created_at , $ uncachedAuthor ->created_at );
2731 $ this ->assertEquals ($ author ->updated_at , $ uncachedAuthor ->updated_at );
2832 $ this ->assertEquals ($ author ->email , $ uncachedAuthor ->email );
2933 $ this ->assertEquals ($ author ->name , $ uncachedAuthor ->name );
3034 }
35+
36+ public function testFirstIsNotTheSameAsAll ()
37+ {
38+ $ authors = (new Author )
39+ ->all ();
40+ $ author = (new Author )
41+ ->first ();
42+
43+ $ this ->assertNotEquals ($ authors , $ author );
44+ }
3145}
You can’t perform that action at this time.
0 commit comments