From b5f76a3e16494327ce18e26ee1414c497d2cacde Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 17:47:24 +0100 Subject: [PATCH 1/6] Added first attempt at integrating the SSIKit testing suite --- .gitea/workflows/ci-pipeline.yaml | 32 +++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index f9b4c14..e057826 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -69,6 +69,38 @@ jobs: source venv/bin/activate python manage.py test + ssikit-tests: + needs: test + runs-on: self-hosted + steps: + + - name: Checkout SSIKit repo + uses: actions/checkout@v4 + with: + repository: trustchain-oc1-orchestral + submodules: true + + - name: Install python3-venv (if not already installed) + run: | + sudo apt-get update + sudo apt-get install python3 python3-venv python3-pip -y + + - name: Setup Python environment + run: | + python3 -m venv venv + source venv/bin/activate + + - name: Install dependencies + run: | + source venv/bin/activate + pip install --upgrade pip + # Install any additional dependencies required for SSIKit tests here + pip install -r requirements.txt (if you have a requirements file) + + - name: Execute SSIKit tests + run: | + source venv/bin/activate + python main.py deploy: needs: test From af7649b5cc8f398b1344bf9626e776bcb21757b3 Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 17:51:51 +0100 Subject: [PATCH 2/6] Fixed an oopsie --- .gitea/workflows/ci-pipeline.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index e057826..b54e993 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -77,7 +77,7 @@ jobs: - name: Checkout SSIKit repo uses: actions/checkout@v4 with: - repository: trustchain-oc1-orchestral + repository: trustchain-oc1-orchestral/ssikit_trustchain submodules: true - name: Install python3-venv (if not already installed) From faf7367c20e9b40bdc51685018efe3f4d3fd16ab Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 18:08:46 +0100 Subject: [PATCH 3/6] Specified ref to check out --- .gitea/workflows/ci-pipeline.yaml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index b54e993..f9f053d 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -79,6 +79,9 @@ jobs: with: repository: trustchain-oc1-orchestral/ssikit_trustchain submodules: true + refs: master + # might not be needed + # token: ${{ secrets.SSIKIT_TOKEN }} - name: Install python3-venv (if not already installed) run: | @@ -95,7 +98,7 @@ jobs: source venv/bin/activate pip install --upgrade pip # Install any additional dependencies required for SSIKit tests here - pip install -r requirements.txt (if you have a requirements file) + pip install -r requirements.txt - name: Execute SSIKit tests run: | From f0ab58da74470153d456e49884e4136d937b63b6 Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 18:25:10 +0100 Subject: [PATCH 4/6] Added token to access ssikit repo --- .gitea/workflows/ci-pipeline.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index f9f053d..630647e 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -81,7 +81,7 @@ jobs: submodules: true refs: master # might not be needed - # token: ${{ secrets.SSIKIT_TOKEN }} + token: ${{ secrets.SSIKIT_TOKEN }} - name: Install python3-venv (if not already installed) run: | From 3ff4abd0f7e3f5a0dbd0ab186e6098afe0b24c1b Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 18:55:04 +0100 Subject: [PATCH 5/6] Small typo --- .gitea/workflows/ci-pipeline.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index 630647e..6df7993 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -79,7 +79,7 @@ jobs: with: repository: trustchain-oc1-orchestral/ssikit_trustchain submodules: true - refs: master + ref: master # might not be needed token: ${{ secrets.SSIKIT_TOKEN }} From 34cb23363eac8efd90d3cca014078e047c4a6b81 Mon Sep 17 00:00:00 2001 From: Elijah Date: Thu, 29 Feb 2024 18:58:33 +0100 Subject: [PATCH 6/6] removed sudo commands --- .gitea/workflows/ci-pipeline.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/ci-pipeline.yaml b/.gitea/workflows/ci-pipeline.yaml index 6df7993..c67fadc 100644 --- a/.gitea/workflows/ci-pipeline.yaml +++ b/.gitea/workflows/ci-pipeline.yaml @@ -85,8 +85,8 @@ jobs: - name: Install python3-venv (if not already installed) run: | - sudo apt-get update - sudo apt-get install python3 python3-venv python3-pip -y + apt-get update + apt-get install python3 python3-venv python3-pip -y - name: Setup Python environment run: |