Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
beforeEach(() => {
scheduler = new Rx.TestScheduler();
settings = {
name: 'My Bamboo CI',
username: 'username',
password: 'password',
url: 'http://example.com/',
updateInterval: 10000,
projects: ['PROJECT1-PLAN1', 'PROJECT2-PLAN2']
};
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
settings = {
name: 'My CI',
username: 'username',
password: 'password',
url: 'http://example.com/',
updateInterval: 10000,
projects: ['ID1', 'ID2']
};
});
beforeEach(function() {
settings = {
baseUrl: 'test',
url: 'http://www.example.com/',
name: 'service name',
projects: [],
disabled: false
};
serviceStartResponse = Rx.Observable.return([]);
spyOn(CustomBuildService.prototype, 'start').and.callFake(function() {
this.events.onNext({ eventName: 'serviceStarted' });
return serviceStartResponse;
});
spyOn(CustomBuildService.prototype, 'stop');
controller.registerType(CustomBuildService);
scheduler = new Rx.TestScheduler();
});
beforeEach(function() {
scheduler = new Rx.TestScheduler();
isRunning = false;
settings = {
name: 'My Travis CI',
icon: 'travis/icon.png',
username: 'AdamNowotny',
updateInterval: 10000,
projects: ['AdamNowotny/BuildReactor']
};
buildsJson = JSON.parse(buildFixture);
buildsRunningJson = JSON.parse(buildsRunningFixture);
buildDetailsJson = JSON.parse(buildDetailsFixture);
buildDetailsRunningJson = JSON.parse(buildDetailsRunningFixture);
spyOn(request, 'json').and.callFake(function(options) {
switch (options.url) {
case 'https://api.travis-ci.org/repositories/AdamNowotny/BuildReactor/builds.json':
return Rx.Observable.return(isRunning ? buildsRunningJson : buildsJson);
beforeEach(() => {
scheduler = new Rx.TestScheduler();
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
stub = new StubSuperagent();
spyOn(superagent, 'get').and.returnValue(stub);
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
settings = {
name: 'My CI',
username: 'username',
password: 'password',
url: 'http://example.com/',
updateInterval: 10000,
projects: ['project1', 'project2']
};
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
});
beforeEach(() => {
scheduler = new Rx.TestScheduler();
sinon.stub(requests, 'repositories');
sinon.stub(requests, 'builds');
});