Skip to content

Instantly share code, notes, and snippets.

@chippinkston
Last active April 28, 2016 17:38
Show Gist options
  • Save chippinkston/d8a39c0d6a7a97d64b5e73c60e7ed7be to your computer and use it in GitHub Desktop.
Save chippinkston/d8a39c0d6a7a97d64b5e73c60e7ed7be to your computer and use it in GitHub Desktop.
Moving the declaration into the given() block works. Did direct call rather than using DI/1.
component extends="testbox.system.BaseSpec" accessors="true"{
function beforeAll(){
}
function run( testResults, testBox ){
feature( "Get a Count of Responses", function() {
describe("I want to know how many responses we have in the system"
, function() {
scenario( "Get all Response counts", function(){
given( "I have a Survey ID",function() {
variables.resultsService = new model.services.resultsService();
when("I run the request the for the survey response count", function() {
count = variables.resultsService.countResponses(1);
then("then I should get a struct", function() {
expect(count).toBeStruct();
});
});
});
});
});
});
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment