I'm working on a electron(-nuxt) based application. End to End test re-written with AVA + Spectron. The .click()
function however doesnt seem to work.
I used this template: https://github.com/michalzaq12/electron-nuxt
Everything seems to work except a simple button click.
<footer class="modal-card-foot">
<button id="loginButton" class="button " type="button" @click="login">
Login
</button>
</footer>
test('app should login', async t => {
let app = t.context.app
await app.client.click('#loginButton')
})
The message i got is:
1 test failed
app should login
Error: Test finished without running any assertions
That is truthy because there aren't any assertions. BUT i can see that the Button is never clicked, because that would trigger a "Login failed" message from the app.