/// import * as CSCoreSDK from '../lib/core-sdk'; import * as axios from 'axios'; describe('TestUtils',function(){ it('I am able to set test case through judge!',function(done){ var judge : CSCoreSDK.Judge = new CSCoreSDK.Judge() var session = judge.startNewSession(); session.setNextCase("webapi.posts.list") .then( data => { expect(data.status).toBe(200) }) .then(() => { return axios.get(CSCoreSDK.Judge.DefaultBaseURL+'/posts',{ headers: { "web-api-key" : "TEST_API_KEY", "accept" : "application/json", "accept-language" : "cs-CZ", 'content-type' : 'application/json', "x-judge-session" : session.sessionId } }).then((data) => { done(); }).catch((e) => { console.log(e) }); }); }); });