Last active
April 28, 2016 15:20
-
-
Save chippinkston/b9328544a82fa994d338579a10087862 to your computer and use it in GitHub Desktop.
Example of unfound service - Throws Error: Component [test.model.testDI] has no accessible Member with name [RESULTSSERVICE]under Luccee 4.5.2.018 and TestBox v2.3.0+00044
This file contains 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
component extends="testbox.system.BaseSpec" accessors="true"{ | |
function beforeAll(){ | |
variables.bf = new lib.org.framework.3_1_0.ioc("/model"); | |
variables.bf.addBean("datasource", {"name"="myDSN"}); | |
variables.resultsService = variables.bf.getBean('resultsService'); | |
} | |
function run( testResults, testBox ){ | |
feature( "Survey Reporting", 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() { | |
when("I run the request the for the survey response count", function() { | |
count = variables.resultsService.countResponses(1); | |
then("then I should get a struct of values", function() { | |
expect(count).toBeStruct(); | |
}); | |
}); | |
}); | |
}); | |
}); | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment