File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -510,8 +510,19 @@ public function testExistsRelationshipWhereClauseParsing()
510510
511511 public function testColumnsRelationshipWhereClauseParsing ()
512512 {
513- // ???
514- $ this ->markTestIncomplete ();
513+ $ author = (new Author )->orderBy ('name ' )->first ();
514+
515+ $ authors = collect ([(new Author )->where ('name ' , '= ' , $ author ->name )->first ()]);
516+
517+ $ key = 'genealabslaravelmodelcachingtestsfixturesauthor-name_ ' . $ author ->name . '-first ' ;
518+ $ tags = ['genealabslaravelmodelcachingtestsfixturesauthor ' ];
519+
520+ $ cachedResults = collect ([cache ()->tags ($ tags )->get ($ key )]);
521+
522+ $ liveResults = collect ([(new UncachedAuthor )->where ('name ' , '= ' , $ author ->name )->first ()]);
523+
524+ $ this ->assertEmpty ($ authors ->diffAssoc ($ cachedResults ));
525+ $ this ->assertEmpty ($ liveResults ->diffAssoc ($ cachedResults ));
515526 }
516527
517528 public function testRawWhereClauseParsing ()
You can’t perform that action at this time.
0 commit comments