Ok, I did find out that the url parameters that are set in another spec from the other bundle are being passed in to this spec.
Here is spec 6 from bundle 1:
`
component extends=“coldbox.system.testing.BaseTestCase” {
// executes before all suites+specs in the run() method
function beforeAll(){
// do your own stuff here
// super.setup();
super.beforeAll();
}
// executes after all suites+specs in the run() method
function afterAll(){
super.beforeAll();
// do your own stuff here
}
function run(){
describe( title=“Project, projectHandler”, body=function(){
beforeEach(function(){
reset();
});
it( “should list a max of 100 most recently created projects”, function(){
var event = execute( event=“project:projectHandler.index”);
expect( Arraylen(getRequestContext().getRenderData().DATA.data) ).toBeBetween(1,100);
});
it( “should list 13 most recently created projects”, function(){
url.max = 13;
var event = execute( event=“project:projectHandler.index”);
// debug( getRequestContext().getRenderData() );
expect( Arraylen(getRequestContext().getRenderData().DATA.data) ).toBe(13);
});
it( “should list atleast 1 project by geolocation(santa ana office)”, function(){
url.lat = 33.6948545;
url.lng = -117.8604357;
var event = execute( event=“project:searchHandler.searchByLatLng”);
// debug( getRequestContext().getRenderData() );
expect( ArrayLen(getRequestContext().getRenderData().DATA.data.PROJECTS) ).toBeGTE(1);
});
it( “should list all tasks for a given project”, function(){
url.wbs1 = “4CAL060700”;
var event = execute( event=“project:projectHandler.getAllTasks”);
// debug( getRequestContext().getRenderData() );
expect( ArrayLen(getRequestContext().getRenderData().DATA.data) ).toBeGTE(1);
});
it( “should get 1 task 4CAL060700 00001”, function(){
url.wbs1 = “4CAL060700”;
url.wbs2 = “00001”;
var event = execute( event=“project:projectHandler.view”);
debug( getRequestContext().getRenderData() );
expect( getRequestContext().getRenderData().DATA.data[1].WBS1 ).toBe(“4CAL060700”);
});
it( “should get 1 task 4CAL060700 00001 with full details”, function(){
url.wbs1 = “4CAL060700”;
url.wbs2 = “00002”;
var event = execute( event=“project:projectHandler.getFullDetails”);
debug( getRequestContext().getRenderData() );
expect( getRequestContext().getRenderData().DATA.data[1].WBS1 ).toBe(“4CAL060700”);
});
});
}
}
`
Here are the specs from bundle 2, specs 2 and 3 are getting the URL params from spec 6 above:
`
component extends=“coldbox.system.testing.BaseTestCase” {
// executes before all suites+specs in the run() method
function beforeAll(){
// do your own stuff here
// super.setup();
super.beforeAll();
}
// executes after all suites+specs in the run() method
function afterAll(){
super.beforeAll();
// do your own stuff here
}
function run(){
describe( title=“Project Search, searchHandler”, body=function(){
beforeEach(function(){
reset();
});
it( “should list atleast 1 project by geolocation(santa ana office)”, function(){
url.lat = 33.6948545;
url.lng = -117.8604357;
var event = execute( event=“project:searchHandler.searchByLatLng”);
// debug( getRequestContext().getRenderData() );
expect( ArrayLen(getRequestContext().getRenderData().DATA.data.PROJECTS) ).toBeGTE(1);
});
it( “should find projects whose project name starts with Riverside”, function(){
url.projecttname = “Riverside”;
url.projectnamelike = 1;
var event = execute( event=“project:searchHandler.searchProjects”);
debug( getRequestContext().getRenderData() );
expect( ArrayLen(getRequestContext().getRenderData().DATA.data.PROJECTS) ).toBeGTE(1);
});
it( “should find projects whose project name ends with Riverside with full details”, function(){
url.projecttname = “Riverside”;
url.projectnamelike = 3;
var event = execute( event=“project:searchHandler.searchProjectsFullDetails”);
debug( getRequestContext().getRenderData() );
expect( ArrayLen(getRequestContext().getRenderData().DATA.data.PROJECTS) ).toBeGTE(1);
});
});
}
}
`