maests
Version:
An executable compiler for creating Maestro's yaml-flows with typescript.
30 lines (25 loc) • 566 B
text/typescript
import { getOutput, M } from "maests";
import { openApp } from "@/fixtures/utils/openApp";
import { someScript } from "./utils/script";
// use composable flow easiliy
openApp();
// run script like this
M.runScript(someScript);
// use variables set in someScript
M.assertVisible({ id: getOutput("id") });
// use runFlow to run some flow with condition
M.runFlow({
flow: () => {
M.repeatWhileNotVisible(
{
text: "4",
},
() => {
M.tapOnText("Increment");
}
);
},
condition: {
visible: "Increment",
},
});