{"_id":"hof-util-autofill","_rev":"68-1d2c351c431c9d5684780fa1a6031baf","name":"hof-util-autofill","dist-tags":{"latest":"1.1.4"},"versions":{"1.0.0":{"name":"hof-util-autofill","version":"1.0.0","author":"","license":"MIT","_id":"hof-util-autofill@1.0.0","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"6dd1b4e38f82db9f4af05fbca3899a4f93107ea4","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.0.0.tgz","integrity":"sha512-UBwK7XSEf9fTkREV5DBdDVpHIuUoN+OIe6av/uWLO/eCKET8+yZNPyIZQmCSrv3ws0kryTnE+vTDYP2eMAc3SA==","signatures":[{"sig":"MEYCIQC12CwoRvmJKv0d349APBWJ1389GkOdYjTjqk2c22xxvQIhAMd/G/bbWvLFZN2cdNETEC9A/3gQlYh+AKauKZosPvC6","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"6dd1b4e38f82db9f4af05fbca3899a4f93107ea4","gitHead":"820e996b34bc2178c929046a79376c664287849b","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.1.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.9.4","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.0.0.tgz_1488210017314_0.05768388160504401","host":"packages-18-east.internal.npmjs.com"}},"1.0.1":{"name":"hof-util-autofill","version":"1.0.1","author":"","license":"MIT","_id":"hof-util-autofill@1.0.1","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"a92bfeb96e136f8b1afa9f553d3a1112e79af286","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.0.1.tgz","integrity":"sha512-bSWaObamvRd4Ju1hgsFtYlaXTAZNIPuG0jO1lu5jkbIz/JpPyaUwSLhduvJnYCJ0SCXIrQWI7UgnluIEgQTyrA==","signatures":[{"sig":"MEQCIBPxOTH0woWewc9eQD11MSyRYcVjcIr0syJrEJvT9ZElAiBhguNluAuBkYjLlYOgUR7UF5Bmw+MkHKCm64WI2nifFQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"a92bfeb96e136f8b1afa9f553d3a1112e79af286","gitHead":"a6cd4c3d2afc71ea1e429f43f8f732a65b478392","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.1.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.9.4","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.0.1.tgz_1488210398596_0.7890226647723466","host":"packages-18-east.internal.npmjs.com"}},"1.0.2":{"name":"hof-util-autofill","version":"1.0.2","author":"","license":"MIT","_id":"hof-util-autofill@1.0.2","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"cddd47fcf5ae78147d884137024eb94ea1607970","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.0.2.tgz","integrity":"sha512-SkbV4DQtR0k8OQeqVDFwb2fJGEBlvPjWPMS+wGp8BWsJA+Ok8Bxhg1Vh8PzyVIRgBiwmOvciFKizAPuvzIT1MQ==","signatures":[{"sig":"MEUCIQChZpECWherbepbNMqjJOVWTJ2NnvoRm/Ku6Y3xJZPjewIgVY2sxAGwtzN4c6FRghi+phMoC7qc+6IXJyVFUjoIsrg=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"cddd47fcf5ae78147d884137024eb94ea1607970","gitHead":"671e9f8fc65306fe3741decc9e6eb4c873568e2f","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.1.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.9.4","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.0"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.0.2.tgz_1488215313420_0.10917083057574928","host":"packages-18-east.internal.npmjs.com"}},"1.1.0":{"name":"hof-util-autofill","version":"1.1.0","author":"","license":"MIT","_id":"hof-util-autofill@1.1.0","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"ce76adf335a199075955b9e0e0157ad93ccdaa69","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.1.0.tgz","integrity":"sha512-riyUGzfrtQPX4OCuiR8ykTPHJTth33piSzyZOKZefppteB1x9m8v9Xwui+iKNfq0pMCb6svCuQy7QDHo1cdpXQ==","signatures":[{"sig":"MEYCIQDgudJmPCsgGy8EZvrxuAYxmneXDFbHrL/pcMdKWrvXzQIhAO5uurV2sMMAK/viqq5F6zNsfO0dDZL1SU/KxVMnemGD","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"ce76adf335a199075955b9e0e0157ad93ccdaa69","gitHead":"5617cbfd7c3485b14a439c886aaa6ba68788e1da","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.1.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.9.4","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.1"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.1.0.tgz_1489075353032_0.8114088580477983","host":"packages-12-west.internal.npmjs.com"}},"1.1.1":{"name":"hof-util-autofill","version":"1.1.1","author":"","license":"MIT","_id":"hof-util-autofill@1.1.1","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"b839f54168d9b970c9b3644ff4919b57eff6ad6b","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.1.1.tgz","integrity":"sha512-nRU6ZXa1luUeKwPvPkddIUxdzu2MOSPY/otfLr3oDF73kLzixXtb3e8Ao+yPXbzpriFOpRuJULPC6s2Y4qmgTw==","signatures":[{"sig":"MEYCIQDxxdZzJtZmViQjFOaM8NXhWhgI4np2qsco5bL93O9d1QIhAJt58FuNsiTbU9EHOh3RMrwNA/06g3OozPfzz1iU/XXg","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"b839f54168d9b970c9b3644ff4919b57eff6ad6b","gitHead":"2129fdd229780e571209cb39fe00eabe0cc9e29f","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.1.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.10.0","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.1"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.1.1.tgz_1490263630740_0.5432673350442201","host":"packages-18-east.internal.npmjs.com"}},"1.1.2":{"name":"hof-util-autofill","version":"1.1.2","author":"","license":"MIT","_id":"hof-util-autofill@1.1.2","maintainers":[{"name":"easternbloc","email":"ben@marvell-consulting.com"},{"name":"josephchapman","email":"info@josephchapman.com"},{"name":"lennym","email":"leonard.martin@gmail.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"7e07163d176375bd535d72db1695b2352fedc13a","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.1.2.tgz","integrity":"sha512-qMbRRSUT0CHlVAO9KzjobLUjKhZOHg2oJU36ssbjz7L5k0DHHTLdFNCSsU2eSlFe+NPgxlNKW/X7lo5gNMRRKQ==","signatures":[{"sig":"MEUCIQCALkkS27SD4iMgIP6wXwbUbvptlCnLB78ghKIXBAijYAIgLqW7aPmaWt2/7ifZonGQ2DuINqDUpF97X7w6rbevk64=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"7e07163d176375bd535d72db1695b2352fedc13a","gitHead":"d20a88be8aa5c45eeffd69cd12e7b2a126705229","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"4.4.1","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"6.10.0","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.1"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.1.2.tgz_1490359954992_0.9260582840070128","host":"packages-18-east.internal.npmjs.com"}},"1.1.3":{"name":"hof-util-autofill","version":"1.1.3","author":"","license":"MIT","_id":"hof-util-autofill@1.1.3","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"},{"name":"joefitter","email":"hello@joefitter.com"},{"name":"josephchapman","email":"info@josephchapman.com"},{"name":"easternbloc","email":"ben@marvell-consulting.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"c91c00c9051d2b2b88033ab367310125f9124067","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.1.3.tgz","integrity":"sha512-odv6zOgUe6zFJfF2T0bW+mF8keOqgQRE2pmTVvT9RQ20qk8XFFchkeTULeLqbOF854TaLjib8KW7bfHkE7so0A==","signatures":[{"sig":"MEYCIQCqTUj+tOPKy36TTrDWq+s5z82TB33cpedsgPdGksf9UgIhAPLVIl7gJ2A/q16NUx0CPoz8oy+fnSvW4jv23Br8g1FV","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","gitHead":"c57a58440c2eaf5edc9581cf8804a4380876750e","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"5.4.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"8.8.1","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.1"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.1.3.tgz_1509725705467_0.010238310554996133","host":"s3://npm-registry-packages"}},"1.1.4":{"name":"hof-util-autofill","version":"1.1.4","author":"","license":"MIT","_id":"hof-util-autofill@1.1.4","maintainers":[{"name":"lennym","email":"leonard.martin@gmail.com"},{"name":"joefitter","email":"hello@joefitter.com"},{"name":"josephchapman","email":"info@josephchapman.com"},{"name":"easternbloc","email":"ben@marvell-consulting.com"}],"homepage":"https://github.com/lennym/hof-util-autofill#readme","bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"dist":{"shasum":"3105ca5b2166dc0229feca366360441bb902f7e9","tarball":"https://registry.npmjs.org/hof-util-autofill/-/hof-util-autofill-1.1.4.tgz","integrity":"sha512-LRZtItLRiayDBuk1V4TqMf8mG6tuYzBM6owx9xNAX3EglygPnm+s3igPAdEDWVWBrPlZMW3kx6g2iDdS0W8A/g==","signatures":[{"sig":"MEUCICrlCS8emIazlDOy8b0bpP1KxwF5YgV3nMYtNNOudovpAiEA49AIxDB98NN9pJqhGdPRNeQUxA3ymQvfpoNV+BbVAEA=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","gitHead":"1b44e2e25dd70850157fc082240b9e45af3b2b3c","scripts":{"test":"eslint ."},"_npmUser":{"name":"lennym","email":"leonard.martin@gmail.com"},"repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"_npmVersion":"5.4.2","description":"A webdriverio plugin to automate filling a form","directories":{},"_nodeVersion":"8.8.1","dependencies":{"debug":"^2.6.1","bluebird":"^3.4.7","hof-util-testdata":"^1.0.1"},"devDependencies":{"eslint":"^4.10.0","eslint-config-homeoffice":"^2.2.0"},"_npmOperationalInternal":{"tmp":"tmp/hof-util-autofill-1.1.4.tgz_1512059628958_0.4281210422050208","host":"s3://npm-registry-packages"}}},"time":{"created":"2017-02-27T15:40:17.999Z","modified":"2026-09-21T15:12:55.499Z","1.0.0":"2017-02-27T15:40:17.999Z","1.0.1":"2017-02-27T15:46:39.192Z","1.0.2":"2017-02-27T17:08:34.098Z","1.1.0":"2017-03-09T16:02:34.676Z","1.1.1":"2017-03-23T10:07:11.377Z","1.1.2":"2017-03-24T12:52:35.941Z","1.1.3":"2017-11-03T16:15:06.392Z","1.1.4":"2017-11-30T16:33:49.817Z"},"bugs":{"url":"https://github.com/lennym/hof-util-autofill/issues"},"license":"MIT","homepage":"https://github.com/lennym/hof-util-autofill#readme","repository":{"url":"git+https://github.com/lennym/hof-util-autofill.git","type":"git"},"description":"A webdriverio plugin to automate filling a form","maintainers":[{"email":"aaron.russell@digital.homeoffice.gov.uk","name":"aaronrussellho"},{"email":"sas-hof-test@digital.homeoffice.gov.uk","name":"hof-bot-user"},{"email":"dk4g.blob@gmail.com","name":"dk4g"},{"email":"gregory.wolverson@digital.homeoffice.gov.uk","name":"greg_wolverson_ho"},{"email":"vinodha.samiyappan@digital.homeoffice.gov.uk","name":"vinodha.s"},{"email":"megan.john@digital.homeoffice.gov.uk","name":"meganjohn"},{"email":"nese.zorba@digital.homeoffice.gov.uk","name":"nzorba"},{"email":"rayhannur.rohman@digital.homeoffice.gov.uk","name":"rayhannurrohmanho"},{"email":"vivek.kumar1@digital.homeoffice.gov.uk","name":"vivekkumar-ho"},{"email":"leonard.martin@gmail.com","name":"lennym"}],"readme":"# hof-util-autofill\nA webdriverio plugin to automate filling a form\n\n## Usage\n\nFirst, add the command to your webdriverio client:\n\n```js\nconst webdriver = require('webdriverio');\nconst client = webdriver.remote(options);\n\nclient.addCommand('goto', require('hof-util-autofill')(client));\n```\n\nThe command can be given any name you like, here we've called it `goto`.\n\nThen you can use the command as normal as part of your webdriver command chain.\n\n```js\nit('completes a form to a certain step automatically', () => {\n  return browser.goto('/confirm')\n    .getUrl()\n    .then((url) => {\n      assert.ok(url.indexOf('/confirm') > -1);\n    });\n});\n\nit('uses any data passed as a second argument to fill out the form', () => {\n  const inputs = { 'first-name': 'David', 'last-name': 'Hasselhoff' };\n  return browser.goto('/confirm', inputs)\n    .$('span.full-name')\n    .getText()\n    .then(name => {\n      assert.equal(name, 'David HasselHoff');\n    });\n});\n\nit('saves screenshots of errors to specified screenshot location', () => {\n  const inputs = {};\n  return browser.goto('/confirm', inputs, { screenshots: '/path/to/output/dir' });\n});\n\nit('tries a pre-specified number of times to get past stuck loops', () => {\n  const inputs = {};\n  return browser.goto('/confirm', inputs, { maxLoops: 1 });\n});\n```\n\n## Options\n\nOptions are passed as a third argument to the exposed method. The following options are available:\n\n* `maxLoops` - determines how many times a step will retry if it resolves back to itself on submission before failing. Default: `3`\n* `screenshots` - specifies a location to save screenshots of the page when it gets stuck. If not specified then no screenshots are saved.\n","readmeFilename":"README.md"}