@abaplint/runtime 2.10.38 → 2.10.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/src/index.d.ts +1 -2
- package/build/src/index.js +1 -3
- package/package.json +1 -1
- package/build/src/unit_test.d.ts +0 -26
- package/build/src/unit_test.js +0 -76
package/build/src/index.d.ts
CHANGED
|
@@ -2,7 +2,6 @@ import { Context } from "./context";
|
|
|
2
2
|
import { OffsetLength } from "./offset_length";
|
|
3
3
|
import { Statements } from "./statements";
|
|
4
4
|
import { templateFormatting } from "./template_formatting";
|
|
5
|
-
import { UnitTestResult } from "./unit_test";
|
|
6
5
|
import * as builtin from "./builtin";
|
|
7
6
|
import * as compare from "./compare";
|
|
8
7
|
import * as DB from "./db/db";
|
|
@@ -17,7 +16,7 @@ import { MemoryConsole } from "./console/memory_console";
|
|
|
17
16
|
import { buildDbTableName } from "./prefix";
|
|
18
17
|
import { IntegerFactory } from "./integer_factory";
|
|
19
18
|
import { dynamicCallLookup } from "./dynamic_call_lookup";
|
|
20
|
-
export {
|
|
19
|
+
export { RFC, types, DB, MemoryConsole };
|
|
21
20
|
export type RuntimeDatabaseOptions = {
|
|
22
21
|
schemaPrefix?: string;
|
|
23
22
|
tablePrefix?: string;
|
package/build/src/index.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ABAP = exports.MemoryConsole = exports.DB = exports.types = exports.RFC =
|
|
3
|
+
exports.ABAP = exports.MemoryConsole = exports.DB = exports.types = exports.RFC = void 0;
|
|
4
4
|
const context_1 = require("./context");
|
|
5
5
|
const offset_length_1 = require("./offset_length");
|
|
6
6
|
const statements_1 = require("./statements");
|
|
7
7
|
const template_formatting_1 = require("./template_formatting");
|
|
8
|
-
const unit_test_1 = require("./unit_test");
|
|
9
|
-
Object.defineProperty(exports, "UnitTestResult", { enumerable: true, get: function () { return unit_test_1.UnitTestResult; } });
|
|
10
8
|
const builtin = require("./builtin");
|
|
11
9
|
const compare = require("./compare");
|
|
12
10
|
const DB = require("./db/db");
|
package/package.json
CHANGED
package/build/src/unit_test.d.ts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
declare class UnitTestMethodResult {
|
|
2
|
-
readonly name: string;
|
|
3
|
-
result: "Pass" | "Fail" | "Skip" | undefined;
|
|
4
|
-
constructor(name: string);
|
|
5
|
-
pass(): void;
|
|
6
|
-
fail(): void;
|
|
7
|
-
skip(): void;
|
|
8
|
-
}
|
|
9
|
-
declare class UnitTestClassResult {
|
|
10
|
-
readonly name: string;
|
|
11
|
-
methods: UnitTestMethodResult[];
|
|
12
|
-
constructor(name: string);
|
|
13
|
-
addMethod(name: string): UnitTestMethodResult;
|
|
14
|
-
}
|
|
15
|
-
declare class UnitTestObjectResult {
|
|
16
|
-
readonly name: string;
|
|
17
|
-
classes: UnitTestClassResult[];
|
|
18
|
-
constructor(name: string);
|
|
19
|
-
addTestClass(name: string): UnitTestClassResult;
|
|
20
|
-
}
|
|
21
|
-
export declare class UnitTestResult {
|
|
22
|
-
objects: UnitTestObjectResult[];
|
|
23
|
-
addObject(name: string): UnitTestObjectResult;
|
|
24
|
-
xUnitXML(): string;
|
|
25
|
-
}
|
|
26
|
-
export {};
|
package/build/src/unit_test.js
DELETED
|
@@ -1,76 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UnitTestResult = void 0;
|
|
4
|
-
/* eslint-disable max-len */
|
|
5
|
-
class UnitTestMethodResult {
|
|
6
|
-
constructor(name) {
|
|
7
|
-
this.name = name;
|
|
8
|
-
this.result = undefined;
|
|
9
|
-
this.result = undefined;
|
|
10
|
-
}
|
|
11
|
-
pass() {
|
|
12
|
-
this.result = "Pass";
|
|
13
|
-
}
|
|
14
|
-
fail() {
|
|
15
|
-
this.result = "Fail";
|
|
16
|
-
}
|
|
17
|
-
skip() {
|
|
18
|
-
this.result = "Skip";
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
class UnitTestClassResult {
|
|
22
|
-
constructor(name) {
|
|
23
|
-
this.name = name;
|
|
24
|
-
this.methods = [];
|
|
25
|
-
}
|
|
26
|
-
addMethod(name) {
|
|
27
|
-
const ret = new UnitTestMethodResult(name);
|
|
28
|
-
this.methods.push(ret);
|
|
29
|
-
return ret;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
class UnitTestObjectResult {
|
|
33
|
-
constructor(name) {
|
|
34
|
-
this.name = name;
|
|
35
|
-
this.classes = [];
|
|
36
|
-
}
|
|
37
|
-
addTestClass(name) {
|
|
38
|
-
const ret = new UnitTestClassResult(name);
|
|
39
|
-
this.classes.push(ret);
|
|
40
|
-
return ret;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
class UnitTestResult {
|
|
44
|
-
constructor() {
|
|
45
|
-
this.objects = [];
|
|
46
|
-
}
|
|
47
|
-
addObject(name) {
|
|
48
|
-
const ret = new UnitTestObjectResult(name);
|
|
49
|
-
this.objects.push(ret);
|
|
50
|
-
return ret;
|
|
51
|
-
}
|
|
52
|
-
xUnitXML() {
|
|
53
|
-
// https://xunit.net/docs/format-xml-v2
|
|
54
|
-
// <assemblies> = project
|
|
55
|
-
// <assembly> = global object/global class
|
|
56
|
-
// <collection> = local class
|
|
57
|
-
// <test> = method
|
|
58
|
-
let ret = `<?xml version="1.0" encoding="utf-8"?>\n<assemblies>\n`;
|
|
59
|
-
for (const obj of this.objects) {
|
|
60
|
-
ret += ` <assembly name="${obj.name}" test-framework="abap-framework" environment="abap-environment">\n`;
|
|
61
|
-
for (const clas of obj.classes) {
|
|
62
|
-
ret += ` <collection name="${clas.name}">\n`;
|
|
63
|
-
for (const meth of clas.methods) {
|
|
64
|
-
ret += ` ` +
|
|
65
|
-
`<test name="${obj.name}.${clas.name}.${meth.name}" type="${obj.name}.${clas.name}" method="${obj.name}.${clas.name}.${meth.name}" time="0" result="${meth.result}"></test>\n`;
|
|
66
|
-
}
|
|
67
|
-
ret += ` </collection>\n`;
|
|
68
|
-
}
|
|
69
|
-
ret += ` </assembly>\n`;
|
|
70
|
-
}
|
|
71
|
-
ret += `</assemblies>`;
|
|
72
|
-
return ret;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
exports.UnitTestResult = UnitTestResult;
|
|
76
|
-
//# sourceMappingURL=unit_test.js.map
|