Skip to content

Commit

Permalink
Merge branch 'master' into j-halili/EMA-4088_add-action-flows-import-…
Browse files Browse the repository at this point in the history
…export-analyze-functionality
  • Loading branch information
jetmirhalili11 authored Aug 27, 2024
2 parents 62feaa5 + 23001a2 commit 81304e8
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@celonis/content-cli",
"version": "0.10.1",
"version": "0.11.1",
"description": "CLI Tool to help manage content in Celonis EMS",
"main": "content-cli.js",
"bin": {
Expand Down
24 changes: 24 additions & 0 deletions src/interfaces/diff-package.transport.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,38 @@ export interface ConfigurationChangeTransport {
export interface NodeDiffTransport {
nodeKey: string;
changes: ConfigurationChangeTransport[];
baseConfiguration: NodeConfiguration;
}

export interface NodeConfiguration {
[key: string]: any;
}

export interface PackageDiffTransport {
packageKey: string;
basePackageConfiguration: PackageConfiguration;
packageChanges: ConfigurationChangeTransport[];
nodesWithChanges: NodeDiffTransport[];
}

export interface PackageConfiguration {
variables?: VariableDefinition[];
dependencies?: PackageDependency[];
[key: string]: any;
}

export interface PackageDependency {
key: string;
version: string;
[key: string]: any;
}

export interface VariableDefinition {
key: string;
type: string;
[key: string]: any;
}

export interface PackageDiffMetadata {
packageKey: string;
hasChanges: boolean;
Expand Down
8 changes: 6 additions & 2 deletions tests/config/config-diff.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ describe("Config diff", () => {

const diffResponse: PackageDiffTransport[] = [{
packageKey: "package-key",
basePackageConfiguration: {metadata: {description: "test"}},
packageChanges: [
{
op: "add",
Expand All @@ -72,7 +73,8 @@ describe("Config diff", () => {
path: "/test",
from: "bbb",
value: JSON.parse("234")
}]
}],
baseConfiguration: {}
}]
}];

Expand Down Expand Up @@ -100,6 +102,7 @@ describe("Config diff", () => {

const diffResponse: PackageDiffTransport[] = [{
packageKey: "package-key",
basePackageConfiguration: {metadata: {description: "test"}},
packageChanges: [
{
op: "add",
Expand All @@ -114,7 +117,8 @@ describe("Config diff", () => {
path: "/test",
from: "bbb",
value: JSON.parse("234")
}]
}],
baseConfiguration: {}
}]
}];

Expand Down

0 comments on commit 81304e8

Please sign in to comment.