From 50ac4d0a42b1d2859ecfe8750e6062ca1bdff854 Mon Sep 17 00:00:00 2001 From: Xiwen Cheng Date: Sun, 8 Sep 2024 20:32:33 +0200 Subject: [PATCH] fix clean up --- .github/workflows/ci.yml | 6 +++--- lint/lint_test.go | 2 +- resources/{ => policies}/001_0003_security_checks.rego | 0 3 files changed, 4 insertions(+), 4 deletions(-) rename resources/{ => policies}/001_0003_security_checks.rego (100%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c9eb02a..ec620d2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -20,18 +20,18 @@ jobs: go-version: 1.22 - name: Build - run: go build -o bin/mendix-cli "./cmd/mendix-cli" + run: go build -o bin/mxlint-cli "./cmd/mxlint-cli" - name: Test run: go test -v ./... - name: Test subcommand export-model run: | - bin/mendix-cli export-model --mode advanced -i resources/app + bin/mxlint-cli export-model --mode advanced -i resources/app git diff --exit-code modelsource - name: Test subcommand lint - run: ./bin/mendix-cli lint --xunit-report report.xml + run: ./bin/mxlint-cli lint --xunit-report report.xml --policies ./resources/policies - name: Process xunit-report uses: dorny/test-reporter@v1 diff --git a/lint/lint_test.go b/lint/lint_test.go index 6b94319..12ccf3f 100644 --- a/lint/lint_test.go +++ b/lint/lint_test.go @@ -18,7 +18,7 @@ func TestLintSingle(t *testing.T) { // } // }) t.Run("single policy passes", func(t *testing.T) { - policy, _ := parsePolicyMetadata("./../resources/001_0003_security_checks.rego") + policy, _ := parsePolicyMetadata("./../resources/policies/001_0003_security_checks.rego") result, err := evalTestsuite(*policy, "./../modelsource") if err != nil { diff --git a/resources/001_0003_security_checks.rego b/resources/policies/001_0003_security_checks.rego similarity index 100% rename from resources/001_0003_security_checks.rego rename to resources/policies/001_0003_security_checks.rego