Created
September 28, 2013 03:31
-
-
Save indirect/6738064 to your computer and use it in GitHub Desktop.
Iterate over an array creating CasperJS steps for each element
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
casper = require('casper').create() | |
casper.start 'http://docs.casperjs.org/en/latest/', -> | |
createWeekStep = (weekNum, index, weeks) -> | |
@then -> console.log("running step for week #{weekNum}") | |
(i for i in [1..12]).forEach(createWeekStep, @) | |
casper.run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment