Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed js and ts examples refers to create-nightwatch issue 99 #7

Merged
merged 1 commit into from
Oct 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions assets/js-examples-new/examples/basic/duckDuckGo.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ describe('duckduckgo example', function() {
.waitForElementVisible('input[name=q]')
.sendKeys('input[name=q]', ['Nightwatch.js'])
.click('*[type="submit"]')
.assert.visible('.results--main')
.assert.textContains('.results--main', 'Nightwatch.js');
.assert.visible('#react-layout')
.assert.textContains('#react-layout', 'Nightwatch.js');
});
});
2 changes: 1 addition & 1 deletion assets/js-examples-new/page-objects/google/search.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ module.exports = {

elements: {
searchBar: {
selector: 'input[name=q]'
selector: 'textarea[name=q]'
},

submitButton: {
Expand Down
4 changes: 2 additions & 2 deletions assets/js-examples/duckDuckGo.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ describe('duckduckgo example', function() {
.waitForElementVisible('#search_form_input_homepage')
.sendKeys('#search_form_input_homepage', ['Nightwatch.js'])
.click('#search_button_homepage')
.assert.visible('.results--main')
.assert.textContains('.results--main', 'Nightwatch.js');
.assert.visible('#react-layout')
.assert.textContains('#react-layout', 'Nightwatch.js');
});
});
4 changes: 2 additions & 2 deletions assets/ts-examples/duckDuckGo.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ describe('duckduckgo example', function(this: ExtendDescribeThis<CustomThis>) {
.waitForElementVisible(this.searchBox!)
.sendKeys(this.searchBox!, ['Nightwatch.js'])
.click(this.submitButton!)
.assert.visible('.react-results--main')
.assert.textContains('.react-results--main', 'Nightwatch.js');
.assert.visible('#react-layout')
.assert.textContains('#react-layout', 'Nightwatch.js');
});
});
2 changes: 1 addition & 1 deletion assets/ts-examples/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const home: NightwatchTests = {
.waitForElementVisible('div[data-testid="results-list"]:first-child')
.assert.textContains(
'div[data-testid="results-list"]:first-child',
'End-to-end testing framework written in Node.js and using the W3C Webdriver API'
'Integrated end-to-end testing framework written in Node.js and using W3C Webdriver API'
);
},

Expand Down