Questions tagged [nightwatch]

This tag should be used to ask questions about the e2e testing framework Nightwatch

This tag should be used to ask questions about the e2e testing framework Nightwatch

Nightwatch.js is an automated testing framework for web applications and websites, written in Node.js and using the W3C WebDriver API

123 questions
1
vote
1 answer

How to run all testcase of a file from other test file in nightwatch

I am trying to run a testfile which has multiple testcase inside it from another test file. let's say, i have admin-registration.js test file which has multiple testcase in it. I have to run all the testcase of admin-registration.js from another…
1
vote
0 answers

How to send a post request using CURL in nightwatch?

I have a use case requirement where i have to send a post request using a curl command before running ANY test in Nightwatch. Example: "curl -X POST https://example.com/". I am aware that there is something called globals in nightwatch where a…
Prabhat
  • 33
  • 9
1
vote
1 answer

How to verify the text in a paragraph element in Nightwatch?

I have a text on a page and i have to verify that the text is present. The html for the element is

The Tesla is part of the

Prabhat
  • 33
  • 9
1
vote
1 answer

Navigate context menu with nightwatch.js?

Im using nightwatchjs and having some difficulties with selecting a text and triggering a right-click and navigate a context menu that I built. This image is an example of what im trying to achieve. Select the 1957 text, right click, nagivate to…
jfr01
  • 107
  • 1
  • 11
1
vote
2 answers

How to check value of tooltip in nightwatch

I'm writing a test which checks that some text appears when you hover over a link. Currently unable to do this as the DOM doesn't change on hover so there's no element to check. See html below:
  • Codr
    • 57
    • 8
  • 1
    vote
    1 answer

    Nightwatcher selenium. How to press: CTRL + SHIFT + j

    I have tried every combination I came up with with no success. browser.keys( [ browser.Keys.CONTROL, browser.Keys.SHIFT, 'j' ] ) browser.keys( browser.Keys.CONTROL + browser.Keys.SHIFT + 'j' ) browser.setValue('.some_elem', […
    educob
    • 83
    • 1
    • 1
    • 7
    1
    vote
    0 answers

    ancestors.shift is not a function

    I'm trying to get automated tests back up and running and having the following issue when I run a test. The objective of the function is if the selector comes from a section of a page object selector will be an array of objects starting from the…
    1
    vote
    1 answer

    Nightwatch using chromedriver version 83 returns `undefined` global values on script

    Hi to all and this is the first time I'm posting at StackOverflow. My nightwatch script with a chromedriver version 77 was working before until I've updated to version 83 which throws a string value of undefined from the global variables at…
    1
    vote
    1 answer

    nightwatch :session not created: This version of ChromeDriver only supports Chrome version 81

    Anyone know how to fix this error on the terminal when you run a test in nightwatch. My Chrome version is the 83, but I don't know if I have to change something on the package-json or update something
    MFL
    • 37
    • 4
    1
    vote
    0 answers

    An error occurred while running .click() command on : from target frame detached in NightwatchJS

    I'm getting this error in Nightwatch when trying to click submit in an iframe this is my code: .perform(() => { client.getAttribute('#myiframe', 'id', result => { client .frame(result.value) …
    1
    vote
    1 answer

    safaridriver: unrecognized option '--w3c'

    I'm trying to run a test against safari running on an iPhone in BrowserStack. Using nightwatch test framework. When I launch the runner from my IDE(IntelliJ), I see this error: /usr/local/bin/node…
    anutter
    • 366
    • 2
    • 17
    1
    vote
    2 answers

    Upgrading the night-watch from 1.3.2 to 1.3.4 breaks the existing test specially in page object

    I was using night-watch version 1.3.2. All the tests were working fine till I update the night-watch to its latest version 1.3.4. The test breaks specially in the page object. I've checked the release notes for night-watch 1.3.4 and it has the new…
    1
    vote
    1 answer

    Nightwatch - Cannot click on elements in Safari (Catalina)

    Nightwatch: 1.3.4 Safari: 13.0 OS X: 10.15.3 I'm trying to set up my tests for Safari using Nightwatch.js and I'm running into a roadblock. For some reason, I'm unable to click on anything (whereas with the other browsers, I can). Here's a simple…
    1
    vote
    1 answer

    How to press CTRL+J (and CTRL+W) keys with Nightwatch.JS

    I need to close Chrome download bar with Nightwatch.JS. In order to do so I want to press CONTROL+J and then CONTROL+W. However, the following code doesn't work: client.keys([client.Keys.CONTROL, "\Ue006A"]); Neither…
    1
    vote
    3 answers

    How .elements() works in nightwatch?

    Considering I have multiple trs I want to pick one and edit value in it by clicking edit button bounded to it. I'm doing something like this: browser.elements('css selector', '#someId tr', elements => { elements.value.forEach(val => { …
    kkot
    • 477
    • 2
    • 6
    • 13
    1
    2
    3
    8 9