Skip to content

Commit

Permalink
chore(cypress): add example test
Browse files Browse the repository at this point in the history
  • Loading branch information
willian-viana committed Sep 14, 2023
1 parent dc7251f commit 3c318e1
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cypress/e2e/duckduckgo.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Feature: duckduckgo.com
Scenario: visiting the frontpage
When I visit duckduckgo.com
Then I should see a search bar
13 changes: 13 additions & 0 deletions cypress/e2e/duckduckgo.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { When, Then } from '@badeball/cypress-cucumber-preprocessor';

When('I visit duckduckgo.com', () => {
cy.visit('https://www.duckduckgo.com');
});

Then('I should see a search bar', () => {
cy.get('input#searchbox_input').should(
'have.attr',
'placeholder',
'Search the web without being tracked'
);
});

0 comments on commit 3c318e1

Please sign in to comment.