From 8554aacc6794c3e61aeba93a18325a6e06340907 Mon Sep 17 00:00:00 2001 From: Denis Smet Date: Thu, 14 Mar 2024 01:05:49 +0400 Subject: [PATCH] Update Docker actions in GitHub Workflow Added distinct Docker run actions for valid and invalid CSV file validation in the GitHub workflows main.yml file. Extended the workflow steps to individually deal with valid and invalid CSV files. Related image and volume parameters have been adjusted accordingly to run the validation tests properly. --- .github/workflows/main.yml | 23 ++++++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 60422c44..bf96b2cd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -227,8 +227,25 @@ jobs: - name: 🐳 Building Docker Image run: make build-docker - - name: Trying to use the Docker Image + - name: Test help and logo run: docker run --rm jbzoo/csv-blueprint --ansi - - name: Reporting example via Docker - run: ! make demo-docker --no-print-directory + - name: 👍 Valid CSV file + run: | + docker run --rm \ + -v `pwd`:/parent-host \ + jbzoo/csv-blueprint \ + validate:csv \ + --csv=/parent-host/tests/fixtures/demo.csv \ + --schema=/parent-host/tests/schemas/demo_valid.yml \ + --ansi + + - name: 👎 Invalid CSV file + run: | + ! docker run --rm \ + -v `pwd`:/parent-host \ + jbzoo/csv-blueprint \ + validate:csv \ + --csv=/parent-host/tests/fixtures/demo.csv \ + --schema=/parent-host/tests/schemas/demo_invalid.yml \ + --ansi