pioneer
pioneer copied to clipboard
`undefined is not a function` in Widget.Form
holaaaaaa,
am I doing something wrong here?
@When /^I enter incorrect values for all of the form fields$/, ->
form = new @Widget.Form.extend
root: 'form'
form.submitWith
subdomain: 'testingtesting0000'
password: 'abc123abc123'
email: '[email protected]'
When I enter incorrect values for all of the form fields
TypeError: undefined is not a function
at Object.<anonymous> (/Applications/wordpress-4.0-1/apps/wordpress/htdocs/wp-content/themes/dt-the7-child/js/tests/steps/signup.coffee:91:19)
at /Applications/wordpress-4.0-1/apps/wordpress/htdocs/wp-content/themes/dt-the7-child/js/node_modules/pioneer/lib/support/index.js:65:25
at webdriver.promise.ControlFlow.runInNewFrame_ (/Applications/wordpress-4.0-1/apps/wordpress/htdocs/wp-content/themes/dt-the7-child/js/node_modules/pioneer/node_modules/selenium-webdriver/lib/webdriver/promise.js:1654:20)
at webdriver.promise.ControlFlow.runEventLoop_ (/Applications/wordpress-4.0-1/apps/wordpress/htdocs/wp-content/themes/dt-the7-child/js/node_modules/pioneer/node_modules/selenium-webdriver/lib/webdriver/promise.js:1518:8)
Then I should see errors for all of the fields
I suspect you're not newing the right thing.
Try
LoginForm = @Widget.Form.extend({ blah })
form = new LoginForm
@tomhicks that looks correct..
@moimikey let me know if this is still not working for you