If you are using Nightwatch JS to test a website and you need to test an anchor nested in a unsorted list, be sure to add the name attribute in the anchor, otherwise, the click command will fail. Let’s see a simple case with an HTML markup like this:

The Nightwatch test below will fail the click.

You can fix it by using: