testdriverai 4.0.15 → 4.0.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +9 -1
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -17,6 +17,7 @@ const path = require('path');
17
17
  const chalk = require('chalk')
18
18
  const yaml = require('js-yaml');
19
19
  const macScreenPerms = require('mac-screen-capture-permissions');
20
+ const clipboardy = require('clipboardy');
20
21
 
21
22
  // local modules
22
23
  const speak = require('./lib/speak');
@@ -748,7 +749,14 @@ ${yaml.dump(step)}
748
749
 
749
750
 
750
751
  const promptUser = () => {
751
- rl.prompt(true);
752
+ // Case where it doesn't execute the command but pastes the clipboard content
753
+ if (rl.on) {
754
+ rl.on('paste', () => {
755
+ const clipboardContent = clipboardy.readSync();
756
+ rl.write(clipboardContent);
757
+ });
758
+ }
759
+ rl.prompt(true);
752
760
  }
753
761
 
754
762
  const iffy = async (condition, then, otherwise, depth) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "testdriverai",
3
- "version": "4.0.15",
3
+ "version": "4.0.16",
4
4
  "description": "Next generation autonomous AI agent for end-to-end testing of web & desktop",
5
5
  "main": "index.js",
6
6
  "bin": {