Skip to content

Commit

Permalink
feat: add "CodeCrafters internal error" to anticheat error scenarios
Browse files Browse the repository at this point in the history
  • Loading branch information
ryan-gang committed May 23, 2024
1 parent acd143e commit 1579cfa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/anti_cheat.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ import (
func antiCheatTest(stageHarness *test_case_harness.TestCaseHarness) error {
b := redis_executable.NewRedisExecutable(stageHarness)
if err := b.Run(); err != nil {
return err
return fmt.Errorf("CodeCrafters internal error. Error instantiating executable: %v", err)
}

logger := stageHarness.Logger

client, err := instrumented_resp_connection.NewFromAddr(stageHarness, "localhost:6379", "replica")
if err != nil {
logFriendlyError(logger, err)
return err
return fmt.Errorf("CodeCrafters internal error. Error creating connection to redis server: %v", err)
}
defer client.Close()

Expand Down

0 comments on commit 1579cfa

Please sign in to comment.