Skip to content

Commit

Permalink
chore: Cleanup E2E tests
Browse files Browse the repository at this point in the history
  • Loading branch information
epociask committed Jun 12, 2024
1 parent 322002e commit 2526d65
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 29 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ jobs:
run: |
make test
- name: Run Optimism Test
- name: Run E2E Tests
run: |
make optimism-test
make e2e-test
gosec:
runs-on: ubuntu-latest
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,13 @@ clean:
rm bin/eigenda-proxy

test:
go test -v ./... -parallel 4
go test -v $(go list ./... | grep -v e2e) -parallel 4

optimism-test:
OPTIMISM=true go test -timeout 1m -v ./e2e -deploy-config ../.devnet/devnetL1.json
e2e-test:
go test -timeout 1m -v ./e2e -parallel 4 -deploy-config ../.devnet/devnetL1.json

holesky-test:
TESTNET=true go test -timeout 50m -v ./e2e -parallel 4
TESTNET=true go test -timeout 50m -v ./e2e -parallel 4 -deploy-config ../.devnet/devnetL1.json

.PHONY: lint
lint:
Expand Down
5 changes: 2 additions & 3 deletions e2e/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,16 @@ import (
)

var (
runOptimismIntegrationTests bool
runTestnetIntegrationTests bool
runTestnetIntegrationTests bool
)

func ParseEnv() {
runOptimismIntegrationTests = os.Getenv("OPTIMISM") == "true" || os.Getenv("OPTIMISM") == "1"
runTestnetIntegrationTests = os.Getenv("TESTNET") == "true" || os.Getenv("TESTNET") == "1"
}

func TestMain(m *testing.M) {
ParseEnv()
println("runTestnetIntegrationTests:", runTestnetIntegrationTests)
code := m.Run()
os.Exit(code)
}
3 changes: 0 additions & 3 deletions e2e/optimism_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,6 @@ func (a *L2PlasmaDA) ActL1Finalized(t actions.Testing) {
}

func TestOptimism(gt *testing.T) {
if !runOptimismIntegrationTests {
gt.Skip("Skipping OP Stack integration test")
}

proxyTS, close := e2e.CreateTestSuite(gt, true)
defer close()
Expand Down
18 changes: 1 addition & 17 deletions e2e/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,12 @@ import (
)

func useMemory() bool {
if runOptimismIntegrationTests {
return true
}

if runTestnetIntegrationTests {
return false
}

return true
return !runTestnetIntegrationTests
}

func TestPlasmaClient(t *testing.T) {
t.Parallel()

if runOptimismIntegrationTests {
t.Skip("Skipping testnet integration test")
}

ts, kill := e2e.CreateTestSuite(t, useMemory())
defer kill()

Expand All @@ -60,10 +48,6 @@ func TestPlasmaClient(t *testing.T) {
func TestProxyClient(t *testing.T) {
t.Parallel()

if runOptimismIntegrationTests {
t.Skip("Skipping testnet integration test")
}

ts, kill := e2e.CreateTestSuite(t, useMemory())
defer kill()

Expand Down

0 comments on commit 2526d65

Please sign in to comment.