@abapify/adt-atc 0.0.0 → 0.3.6

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.
Files changed (2) hide show
  1. package/README.md +110 -1
  2. package/package.json +42 -3
package/README.md CHANGED
@@ -1,3 +1,112 @@
1
1
  # @abapify/adt-atc
2
2
 
3
- Placeholder. The real release is published via CI/CD.
3
+ [![version](https://img.shields.io/github/package-json/v/abapify/adt-cli?filename=packages/adt-atc/package.json)](https://github.com/abapify/adt-cli/pkgs/npm/%40abapify%2Fadt-atc)
4
+
5
+ ABAP Test Cockpit (ATC) CLI plugin for `@abapify/adt-cli`.
6
+
7
+ ## Installation
8
+
9
+ ```bash
10
+ npm install @abapify/adt-atc
11
+ ```
12
+
13
+ ## Usage
14
+
15
+ ### As a CLI Plugin
16
+
17
+ Add to your `adt.config.ts`:
18
+
19
+ ```typescript
20
+ export default {
21
+ commands: ['@abapify/adt-atc/commands/atc'],
22
+ };
23
+ ```
24
+
25
+ Then use the command:
26
+
27
+ ```bash
28
+ # Run ATC on a transport
29
+ adt atc -t S0DK942970
30
+
31
+ # Run ATC on a package
32
+ adt atc -p ZMY_PACKAGE
33
+
34
+ # Run ATC on a specific object
35
+ adt atc -o /sap/bc/adt/oo/classes/zcl_my_class
36
+
37
+ # Output as SARIF (for GitHub Code Scanning)
38
+ adt atc -t S0DK942970 --format sarif --output atc-results.sarif
39
+
40
+ # Output as GitLab Code Quality
41
+ adt atc -t S0DK942970 --format gitlab --output gl-code-quality.json
42
+ ```
43
+
44
+ ### Options
45
+
46
+ | Option | Description |
47
+ | ----------------------------- | ---------------------------------------------------- |
48
+ | `-p, --package <package>` | Run ATC on package |
49
+ | `-o, --object <uri>` | Run ATC on specific object |
50
+ | `-t, --transport <transport>` | Run ATC on transport request |
51
+ | `--variant <variant>` | ATC check variant (default: from system customizing) |
52
+ | `--max-results <number>` | Maximum number of results (default: 100) |
53
+ | `--format <format>` | Output format: console, json, gitlab, sarif |
54
+ | `--output <file>` | Output file (required for gitlab/sarif format) |
55
+
56
+ ### Programmatic Usage
57
+
58
+ ```typescript
59
+ import {
60
+ atcCommand,
61
+ outputSarifReport,
62
+ outputGitLabCodeQuality,
63
+ } from '@abapify/adt-atc';
64
+ import type { AtcResult, AtcFinding } from '@abapify/adt-atc';
65
+
66
+ // Use the formatters directly
67
+ const result: AtcResult = {
68
+ checkVariant: 'DEFAULT',
69
+ totalFindings: 1,
70
+ errorCount: 0,
71
+ warningCount: 1,
72
+ infoCount: 0,
73
+ findings: [
74
+ {
75
+ checkId: 'CL_CI_TEST_SELECT',
76
+ checkTitle: 'Analysis of WHERE Condition for SELECT',
77
+ messageId: '001',
78
+ priority: 2,
79
+ messageText: 'Table SFLIGHT: No WHERE condition',
80
+ objectUri: '/sap/bc/adt/oo/classes/zcl_my_class',
81
+ objectType: 'CLAS',
82
+ objectName: 'ZCL_MY_CLASS',
83
+ location: '/sap/bc/adt/oo/classes/zcl_my_class/source/main#start=10,0',
84
+ },
85
+ ],
86
+ };
87
+
88
+ await outputSarifReport(result, 'atc-results.sarif');
89
+ await outputGitLabCodeQuality(result, 'gl-code-quality.json');
90
+ ```
91
+
92
+ ## Output Formats
93
+
94
+ ### Console (default)
95
+
96
+ Human-readable output with emoji indicators and clickable ADT links (in supported terminals).
97
+
98
+ ### JSON
99
+
100
+ Raw JSON output of the ATC results for further processing.
101
+
102
+ ### SARIF
103
+
104
+ [SARIF](https://sarifweb.azurewebsites.net/) format for GitHub Code Scanning integration.
105
+
106
+ ### GitLab Code Quality
107
+
108
+ [GitLab Code Quality](https://docs.gitlab.com/ee/ci/testing/code_quality.html) format for GitLab CI/CD integration.
109
+
110
+ ## License
111
+
112
+ MIT
package/package.json CHANGED
@@ -1,5 +1,44 @@
1
1
  {
2
2
  "name": "@abapify/adt-atc",
3
- "version": "0.0.0",
4
- "description": "Placeholder — real package is published via CI/CD (trusted publishing)."
5
- }
3
+ "version": "0.3.6",
4
+ "description": "ABAP Test Cockpit (ATC) CLI plugin for adt-cli",
5
+ "license": "MIT",
6
+ "publishConfig": {
7
+ "access": "public"
8
+ },
9
+ "type": "module",
10
+ "main": "./dist/index.mjs",
11
+ "types": "./dist/index.d.mts",
12
+ "exports": {
13
+ ".": "./dist/index.mjs",
14
+ "./commands/atc": "./dist/commands/atc.mjs",
15
+ "./package.json": "./package.json"
16
+ },
17
+ "files": [
18
+ "dist",
19
+ "README.md"
20
+ ],
21
+ "keywords": [
22
+ "sap",
23
+ "adt",
24
+ "abap",
25
+ "atc",
26
+ "code-quality",
27
+ "sarif",
28
+ "gitlab"
29
+ ],
30
+ "dependencies": {
31
+ "@abapify/adt-plugin": "0.3.6",
32
+ "chalk": "^5.3.0"
33
+ },
34
+ "module": "./dist/index.mjs",
35
+ "repository": {
36
+ "type": "git",
37
+ "url": "git+https://github.com/abapify/adt-cli.git",
38
+ "directory": "packages/adt-atc"
39
+ },
40
+ "homepage": "https://github.com/abapify/adt-cli/tree/main/packages/adt-atc#readme",
41
+ "bugs": {
42
+ "url": "https://github.com/abapify/adt-cli/issues"
43
+ }
44
+ }