I'm trying to test a Laravel sitemap page.
Want to test that a uri 'sitemap/departments.xml' contains '/adhesives-sealants/adhesives/c657'
Here is my code:
$response = $this->get( 'sitemap/departments.xml');
$response->assertSee('/adhesives-sealants/adhesives/c657');
This is the response I get from test:
Failed asserting that '' contains "/interior-exterior-pva-wood-glue/p31670".
When I dump out $response I get this:
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9
http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">
</urlset>
Which is not what is on the page!
Page looks like this:
Where am i going wrong???
Adhesives and sealants can be deformed according to the shape of the sealing surface, and it is not easy to flow and has a certain adhesiveness. It is made of dry or non-drying viscous materials such as asphalt, tar, rubber and resin, and is added with various compounding agents. Adhesives and Sealants testing
RépondreSupprimer