I am testing my Laravel website using Dusk. The problem is that Dusk cant find a certain element. I have copied the element selector using Chrome developer tools and my code looks like this.
$browser->assertSeeIn('#content-container > div > div.table-responsive > table > tbody > tr > td:nth-child(1)', 'Test 1');
I have tried xpath as well. Fails also. I run my tests non-headless so I can see that the correct page is shown. There is something really wrong with Dusk that eventhough it's on the right page it cant find the lement. I have also tried:
$browser->assertSeeIn('table > tbody > tr > td:nth-child(1)', 'Test 1');
What am I missing???