From 414fee535e38b68b61e00158012fcfed32b97850 Mon Sep 17 00:00:00 2001 From: algenreyubang Date: Thu, 3 Apr 2025 13:22:13 +0800 Subject: [PATCH] testing some test cases --- .gitea/workflows/artifacttest.yml | 14 ++++++++++++ .gitea/workflows/envtest.yml | 12 +++++++++++ .gitea/workflows/failtest.yml | 9 ++++++++ .gitea/workflows/test.yml | 36 ++----------------------------- 4 files changed, 37 insertions(+), 34 deletions(-) create mode 100644 .gitea/workflows/artifacttest.yml create mode 100644 .gitea/workflows/envtest.yml create mode 100644 .gitea/workflows/failtest.yml diff --git a/.gitea/workflows/artifacttest.yml b/.gitea/workflows/artifacttest.yml new file mode 100644 index 0000000..f91aadb --- /dev/null +++ b/.gitea/workflows/artifacttest.yml @@ -0,0 +1,14 @@ +name: Artifact Test +on: [push] + +jobs: + artifact-test: + runs-on: ubuntu-latest + steps: + - name: Create test file + run: echo "test content" > test.txt + - name: Upload artifact + uses: actions/upload-artifact@v3 + with: + name: test-file + path: test.txt \ No newline at end of file diff --git a/.gitea/workflows/envtest.yml b/.gitea/workflows/envtest.yml new file mode 100644 index 0000000..132cdd9 --- /dev/null +++ b/.gitea/workflows/envtest.yml @@ -0,0 +1,12 @@ +name: Env Test +on: [push] + +env: + TEST_VAR: "gitea-test-value" + +jobs: + env-test: + runs-on: ubuntu-latest + steps: + - name: Print env var + run: echo "The value is $TEST_VAR" \ No newline at end of file diff --git a/.gitea/workflows/failtest.yml b/.gitea/workflows/failtest.yml new file mode 100644 index 0000000..6287b02 --- /dev/null +++ b/.gitea/workflows/failtest.yml @@ -0,0 +1,9 @@ +name: Failure Test +on: [push] + +jobs: + fail-test: + runs-on: ubuntu-latest + steps: + - name: This should fail + run: exit 1 \ No newline at end of file diff --git a/.gitea/workflows/test.yml b/.gitea/workflows/test.yml index b56aa5a..6b5eb6d 100644 --- a/.gitea/workflows/test.yml +++ b/.gitea/workflows/test.yml @@ -11,39 +11,7 @@ jobs: run: echo "Gitea CI/CD is working!" -on: [push] - -jobs: - artifact-test: - runs-on: ubuntu-latest - steps: - - name: Create test file - run: echo "test content" > test.txt - - name: Upload artifact - uses: actions/upload-artifact@v3 - with: - name: test-file - path: test.txt -on: [push] - -env: - TEST_VAR: "gitea-test-value" - -jobs: - env-test: - runs-on: ubuntu-latest - steps: - - name: Print env var - run: echo "The value is $TEST_VAR" - - -on: [push] - -jobs: - fail-test: - runs-on: ubuntu-latest - steps: - - name: This should fail - run: exit 1 \ No newline at end of file + + \ No newline at end of file