Skip to content

Commit

Permalink
refactor: Update testTxMulti to use TransactionTestCase
Browse files Browse the repository at this point in the history
  • Loading branch information
ryan-gang committed Jun 14, 2024
1 parent a764c12 commit 7b04ff9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions internal/test_txn_multi.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package internal

import (
"github.com/codecrafters-io/redis-tester/internal/redis_executable"
"github.com/codecrafters-io/redis-tester/internal/resp_assertions"
resp_value "github.com/codecrafters-io/redis-tester/internal/resp/value"

"github.com/codecrafters-io/redis-tester/internal/instrumented_resp_connection"
"github.com/codecrafters-io/redis-tester/internal/test_cases"
Expand All @@ -24,11 +24,11 @@ func testTxMulti(stageHarness *test_case_harness.TestCaseHarness) error {
}
defer client.Close()

commandTestCase := test_cases.SendCommandTestCase{
Command: "MULTI",
Args: []string{},
Assertion: resp_assertions.NewStringAssertion("OK"),
transactionTestCase := test_cases.TransactionTestCase{
CommandQueue: [][]string{},
ResultArray: []resp_value.Value{},
ShouldSkipExec: true,
}

return commandTestCase.Run(client, logger)
return transactionTestCase.RunMulti(client, logger)
}

0 comments on commit 7b04ff9

Please sign in to comment.