Hey Alex, what plugin for vscode you use to autocomplete magic methods?
Hey Alex,
What is the point of wrapping the variable function {$method}($url) in curly braces?
It seems to work without those.
Hi! First of all, thanks for the course, looking forward to checking it all out. I am trying the tests you write on a personal project running React with Inertiajs, I noticed it's not possible to test assertSee
I guess this is due to how the page is rendered (sorry, I'm not an experienced dev), is it possible to create those kind of tests using the Inertia stack or should those tests be run using any JS testing framework? Thanks!
You can try the SSR feature in Inertia.
EP 17: Since the actingAs works without chaining, could you instead check to see if $this->value
is an instance of Authenticatable, if so, run acting as, then return the response as you have it in the else. This would get rid of the need to assign the response and the complexities of the if/else. Same end effect, just a bit easier to read.
For some reason, in the episode 4 tests, "assertSeeText" isn't working for me, but "assertSee" works fine. I wonder if anyone else is running into this. I've no idea why "assertSeeText" would be failing (with or without the "escaped" argument).
Aha. The problem was a missing ">" in the head section of app.blade.php. Apparently, if there's a problem with the html, any assertion that uses "strip_tags" (like assertSeeText or assertSeeTextInOrder) will just strip out everything, even though the browser still figures out how to render the page. So I learned something useful.