diff --git a/.gitea/workflows/test_rust.yml b/.gitea/workflows/test_rust.yml new file mode 100644 index 0000000..a1a30f2 --- /dev/null +++ b/.gitea/workflows/test_rust.yml @@ -0,0 +1,15 @@ +name: Test Rust + +on: + push: + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Build Docker image for testing + run: docker build -f Dockerfile.test -t configotron-rust-test . + + - name: Run tests in Docker container + run: docker run --rm configotron-rust-test \ No newline at end of file diff --git a/Dockerfile.test b/Dockerfile.test new file mode 100644 index 0000000..5fcf1c3 --- /dev/null +++ b/Dockerfile.test @@ -0,0 +1,10 @@ +# Use the official Rust image as the base +FROM rust:latest + +WORKDIR /tester + +COPY . . + +RUN cargo fetch + +CMD ["cargo", "test"] \ No newline at end of file