-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtest.ts
31 lines (27 loc) · 801 Bytes
/
test.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import { SpecReporter, DisplayProcessor } from "jasmine-spec-reporter";
import {Configuration} from "jasmine-spec-reporter/built/configuration";
const Jasmine = require("jasmine");
import SuiteInfo = jasmine.SuiteInfo;
class CustomProcessor extends DisplayProcessor {
public displayJasmineStarted(info: SuiteInfo, log: string): string {
return `TypeScript ${log}`;
}
}
const jrunner = new Jasmine();
jrunner.loadConfig({
spec_dir: 'src',
spec_files: [
"**/*.spec.ts"
],
"stopSpecOnExpectationFailure": false,
"random": false
});
jrunner.env.clearReporters();
jrunner.addReporter(new SpecReporter(<Configuration>{
customProcessors: [CustomProcessor],
spec: {
displayStacktrace: true
}
}));
jrunner.loadConfigFile();
jrunner.execute();