Skip to content

Commit

Permalink
Split out mercury servers to remove test interdependency
Browse files Browse the repository at this point in the history
  • Loading branch information
samsondav committed Nov 19, 2024
1 parent 1341a3a commit f44ab8f
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions core/services/ocr2/plugins/llo/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,11 +342,6 @@ func TestIntegration_LLO(t *testing.T) {
multiplier := decimal.New(1, 18)
expirationWindow := time.Hour / time.Second

reqs := make(chan request, 100000)
serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-1))
serverPubKey := serverKey.PublicKey
srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs)

clientCSAKeys := make([]csakey.KeyV2, nNodes)
clientPubKeys := make([]ed25519.PublicKey, nNodes)
for i := 0; i < nNodes; i++ {
Expand All @@ -366,6 +361,11 @@ func TestIntegration_LLO(t *testing.T) {
bootstrapNode := Node{App: appBootstrap, KeyBundle: bootstrapKb}

t.Run("using legacy verifier configuration contract, produces reports in v0.3 format", func(t *testing.T) {
reqs := make(chan request, 100000)
serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-1))
serverPubKey := serverKey.PublicKey
srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs)

serverURL := startMercuryServer(t, srv, clientPubKeys)

donID := uint32(995544)
Expand Down Expand Up @@ -546,6 +546,11 @@ channelDefinitionsContractFromBlock = %d`, serverURL, serverPubKey, donID, confi
})

t.Run("Blue/Green lifecycle (using JSON report format)", func(t *testing.T) {
reqs := make(chan request, 100000)
serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-2))
serverPubKey := serverKey.PublicKey
srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs)

serverURL := startMercuryServer(t, srv, clientPubKeys)

donID := uint32(888333)
Expand Down

0 comments on commit f44ab8f

Please sign in to comment.