Open nealsanche opened 1 year ago
+1 for biometrics
We are implementing passkeys as a auth mechanism & cannot accept the passkey request in the maestro test without fingerpint
Having the same problem and just grab a workaround from the Maestro Slack channel. We can achieve it by running the localhost server and accessing it via Maestro JavaScript. The localhost can get a request and execute any command in the file system (e.g.: xcrun simctl push …) Hope this help.
@xuanmai-agilityio have you got a code snippet / repo showing how you achieve this?
@peterferguson Not fully tested with the push notification or any simulator/emulator control. But this snippet works with simple commands like ls, la,...
.
curl http://localhost:3000/runcmd\?cmd\=ls
hope this help
const express = require('express');
const { exec } = require('child_process');
const app = express();
const port = 3000;
app.get('/runcmd', (req, res) => {
const cmd = req.query.cmd;
exec(cmd, (error, stdout, stderr) => {
if (error) {
console.error(`Error executing command: ${error.message}`);
res.status(500).send('An error occurred');
} else {
console.log(`Command executed successfully: ${cmd}`);
res.send(stdout);
}
});
});
app.listen(port, () => {
console.log(`Server is running on port ${port}`);
});
+1 for biometrics
We have device authentication for app access that is constantly breaking. Would be great to be able to catch it with automated e2e tests.
There's some docs on Android Developers about simulating fingerprint, dropping it in case it's useful. It's emulator-only, though.
I have an app that I want to automate that performs some fingerprint biometric checks. We really only need to test on one platform, so can restrict it to Android emulators. Would it be possible to add execution of something like:
In Maestro so that the script can provide the necessary fingerprint when needed? I've only just started looking at Maestro and find it promising. Thanks.