MNT Tweak behat test to look for tag with specific attribute itstead of looking for a specifc string in the HTML (#2971)

This commit is contained in:
Maxime Rainville 2024-07-01 10:36:41 +12:00 committed by GitHub
parent 137bf49751
commit 7e10f29817
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -103,11 +103,11 @@ Feature: Edit a page
And I press the "Publish" button
And I go to "/about-us"
# insert from files
Then the rendered HTML should contain "<img src=\"/assets/file1.jpg\""
Then I should see an "img[src='/assets/file1.jpg']" element
# link to a file
Then the rendered HTML should contain "<a href=\"/assets/file1.jpg\">"
Then I should see an "a[href='/assets/file1.jpg']" element
# media embed
Then the rendered HTML should contain "src=\"https://www.youtube.com/embed/ScMzIvxBSi4?feature=oembed\""
Then I should see an "iframe[src='https://www.youtube.com/embed/ScMzIvxBSi4?feature=oembed']" element
Scenario: Change page type
When I click on "About Us" in the tree