From b5dfff99078f52e6554603ce377d5470cdec308b Mon Sep 17 00:00:00 2001 From: dorschw <81086590+dorschw@users.noreply.github.com> Date: Wed, 17 Apr 2024 10:32:06 +0300 Subject: [PATCH 1/4] test conf.json validation --- Tests/conf.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tests/conf.json b/Tests/conf.json index d3336d12f34f..b5f5dc38268f 100644 --- a/Tests/conf.json +++ b/Tests/conf.json @@ -28,7 +28,7 @@ { "playbookID": "playbook-AzureLogAnalytics-test", "integrations": "Azure Log Analytics", - "instance_names": "Azure_Log_Analytics_client_cred", + "instance_name": "Azure_Log_Analytics_client_cred", "timeout": 800, "is_mockable": false }, @@ -6276,4 +6276,4 @@ "IPv6 CIDR extraction test", "IPv6 extraction test" ] -} \ No newline at end of file +} From 6ecf90dd583712d6189d5ca4790fa406dd8ff44c Mon Sep 17 00:00:00 2001 From: dorschw <81086590+dorschw@users.noreply.github.com> Date: Wed, 17 Apr 2024 10:47:35 +0300 Subject: [PATCH 2/4] add hook, fix conf.json --- .pre-commit-config_template.yaml | 9 +++++++++ Tests/conf.json | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config_template.yaml b/.pre-commit-config_template.yaml index 450674cfb7e1..06803918c4a8 100644 --- a/.pre-commit-config_template.yaml +++ b/.pre-commit-config_template.yaml @@ -185,6 +185,7 @@ repos: - Packs - Tests - Utils + - id: validate-content-paths name: validate-content-paths entry: validate-content-path @@ -198,6 +199,14 @@ repos: - --skip-markdown - --skip-suffix + + - id: validate-conf-json + name: validate-conf-json + description: validate conf.json + entry: validate-conf-json + pass_filenames: false + language: system + - id: pwsh-test-in-docker name: pwsh-test-in-docker description: Run powershell tests diff --git a/Tests/conf.json b/Tests/conf.json index b5f5dc38268f..8074ceaab0f5 100644 --- a/Tests/conf.json +++ b/Tests/conf.json @@ -28,7 +28,7 @@ { "playbookID": "playbook-AzureLogAnalytics-test", "integrations": "Azure Log Analytics", - "instance_name": "Azure_Log_Analytics_client_cred", + "instance_names": "Azure_Log_Analytics_client_cred", "timeout": 800, "is_mockable": false }, @@ -3778,7 +3778,7 @@ }, { "integrations": "Generic Webhook", - "instance_name": "Generic Webhook XSOAR on-prem", + "instance_names": "Generic Webhook XSOAR on-prem", "playbookID": "Generic Webhook - Test", "marketplaces": "xsoar_on_prem", "has_api": false From a732dd34f2758902e318818b89ef145889317f8b Mon Sep 17 00:00:00 2001 From: dorschw <81086590+dorschw@users.noreply.github.com> Date: Wed, 17 Apr 2024 10:48:28 +0300 Subject: [PATCH 3/4] no line at the end --- Tests/conf.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/conf.json b/Tests/conf.json index 8074ceaab0f5..83a648e359c9 100644 --- a/Tests/conf.json +++ b/Tests/conf.json @@ -6276,4 +6276,4 @@ "IPv6 CIDR extraction test", "IPv6 extraction test" ] -} +} \ No newline at end of file From 6e65d84fd364e63ae6c3bb8bf8c71151fe579262 Mon Sep 17 00:00:00 2001 From: dorschw <81086590+dorschw@users.noreply.github.com> Date: Wed, 17 Apr 2024 10:53:25 +0300 Subject: [PATCH 4/4] fix `Redmine_Test` --- Tests/conf.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/conf.json b/Tests/conf.json index 83a648e359c9..66730c9d054f 100644 --- a/Tests/conf.json +++ b/Tests/conf.json @@ -5659,7 +5659,7 @@ }, { "integrations": "Redmine", - "playbookID": "Redmine-Test" + "playbookID": "Redmine_Test" }, { "integrations": "Palo Alto Networks AIOps",