Given
Timmy visits the Angular homepage
0s
// With Callbacks
Given (/^Timmy visits the Angular homepage$/, (callback) => {
// Write code here that turns the phrase above into concrete actions
callback(null, 'pending');
});
// With Promises
Given (/^Timmy visits the Angular homepage$/, () => {
// Write code here that turns the phrase above into concrete actions
return Promise.resolve('pending');
});
When
he doesn't do anything
0s
// With Callbacks
When (/^he doesn't do anything$/, (callback) => {
// Write code here that turns the phrase above into concrete actions
callback(null, 'pending');
});
// With Promises
When (/^he doesn't do anything$/, () => {
// Write code here that turns the phrase above into concrete actions
return Promise.resolve('pending');
});
Then
nothing has been done
0s
// With Callbacks
Then (/^nothing has been done$/, (callback) => {
// Write code here that turns the phrase above into concrete actions
callback(null, 'pending');
});
// With Promises
Then (/^nothing has been done$/, () => {
// Write code here that turns the phrase above into concrete actions
return Promise.resolve('pending');
});