diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml deleted file mode 100644 index 9c1ad4ac..00000000 --- a/.github/workflows/actions.yml +++ /dev/null @@ -1,83 +0,0 @@ -# Go test workflow -name: actions - -on: - push: - branches: [ "main" ] - pull_request: - branches: [ "main" ] - -jobs: - build: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - - name: Set up Go - uses: actions/setup-go@v3 - with: - go-version: 1.21 - - - name: Build App - run: make eigenda-proxy - - go-test: - outputs: - COVERAGE: ${{ steps.unit.outputs.coverage }} - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - submodules: true - - - name: Set up Go - uses: actions/setup-go@v3 - with: - go-version: 1.21 - - - name: Install project dependencies - run: | - go mod download - - - name: Run Unit Tests - id: unit - run: | - make test - - - name: Run E2E Tests - run: | - make e2e-test - - gosec: - runs-on: ubuntu-latest - env: - GO111MODULE: on - steps: - - name: Checkout Source - uses: actions/checkout@v3 - - name: Run Gosec Security Scanner - uses: securego/gosec@master - with: - args: ./... - - holesky-test: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - with: - submodules: true - - - name: Set up Go - uses: actions/setup-go@v3 - with: - go-version: 1.21 - - - name: Install project dependencies - run: | - go mod download - - name: Run holesky tests - env: - SIGNER_PRIVATE_KEY: ${{ secrets.SIGNER_PRIVATE_KEY }} - ETHEREUM_RPC: ${{ secrets.ETHEREUM_RPC }} - run: | - SIGNER_PRIVATE_KEY=$SIGNER_PRIVATE_KEY ETHEREUM_RPC=$ETHEREUM_RPC make holesky-test \ No newline at end of file diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 00000000..c31b22ba --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,21 @@ +name: build + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.21 + + - name: Build App + run: make eigenda-proxy \ No newline at end of file diff --git a/.github/workflows/gosec.yml b/.github/workflows/gosec.yml new file mode 100644 index 00000000..d6d7dac9 --- /dev/null +++ b/.github/workflows/gosec.yml @@ -0,0 +1,20 @@ +name: gosec + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + go-sec: + runs-on: ubuntu-latest + env: + GO111MODULE: on + steps: + - name: Checkout Source + uses: actions/checkout@v3 + - name: Run Gosec Security Scanner + uses: securego/gosec@master + with: + args: ./... diff --git a/.github/workflows/holesky-test.yml b/.github/workflows/holesky-test.yml new file mode 100644 index 00000000..2d22878a --- /dev/null +++ b/.github/workflows/holesky-test.yml @@ -0,0 +1,30 @@ +name: holesky-test + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + holesky-test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + submodules: true + + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.21 + + - name: Install project dependencies + run: | + go mod download + - name: Run holesky tests + env: + SIGNER_PRIVATE_KEY: ${{ secrets.SIGNER_PRIVATE_KEY }} + ETHEREUM_RPC: ${{ secrets.ETHEREUM_RPC }} + run: | + SIGNER_PRIVATE_KEY=$SIGNER_PRIVATE_KEY ETHEREUM_RPC=$ETHEREUM_RPC make holesky-test \ No newline at end of file diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml new file mode 100644 index 00000000..e4e0c10d --- /dev/null +++ b/.github/workflows/unit-tests.yml @@ -0,0 +1,35 @@ +name: unit-tests + +on: + push: + branches: [ "main" ] + pull_request: + branches: [ "main" ] + +jobs: + go-test: + outputs: + COVERAGE: ${{ steps.unit.outputs.coverage }} + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + submodules: true + + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version: 1.21 + + - name: Install project dependencies + run: | + go mod download + + - name: Run Unit Tests + id: unit + run: | + make test + + - name: Run E2E Tests + run: | + make e2e-test diff --git a/README.md b/README.md index 11f36566..317b5add 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,8 @@ +![Compiles](https://github.com/Layr-Labs/eigenda-proxy/actions/workflows/build.yml/badge.svg) +![Unit Tests](https://github.com/Layr-Labs/eigenda-proxy/actions/workflows/unit-tests.yml/badge.svg) +![Linter](https://github.com/Layr-Labs/eigenda-proxy/actions/workflows/gosec.yml/badge.svg) +![Integration Tests](https://github.com/Layr-Labs/eigenda-proxy/actions/workflows/holesky-test.yml/badge.svg) + # EigenDA Sidecar Proxy ## Introduction