Skip to content

Commit

Permalink
Revert "fix: test"
Browse files Browse the repository at this point in the history
This reverts commit 1d230cc.
  • Loading branch information
avallete committed Dec 18, 2024
1 parent 1d230cc commit b0f1399
Showing 1 changed file with 1 addition and 18 deletions.
19 changes: 1 addition & 18 deletions internal/start/start_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,7 @@ func TestStartCommand(t *testing.T) {
assert.Empty(t, apitest.ListUnmatchedRequests())
})

t.Run("show status if database is already running", func(t *testing.T) {
var running []types.Container
for _, name := range utils.GetDockerIds() {
running = append(running, types.Container{
Names: []string{name + "_test"},
})
}
t.Run("noop if database is already running", func(t *testing.T) {
// Setup in-memory fs
fsys := afero.NewMemMapFs()
require.NoError(t, utils.WriteConfig(fsys, false))
Expand All @@ -74,17 +68,6 @@ func TestStartCommand(t *testing.T) {
Get("/v" + utils.Docker.ClientVersion() + "/containers").
Reply(http.StatusOK).
JSON(types.ContainerJSON{})

gock.New(utils.Docker.DaemonHost()).
Get("/v" + utils.Docker.ClientVersion() + "/containers/supabase_db_test/json").
Reply(http.StatusOK).
JSON(types.ContainerJSON{ContainerJSONBase: &types.ContainerJSONBase{
State: &types.ContainerState{Running: true},
}})
gock.New(utils.Docker.DaemonHost()).
Get("/v" + utils.Docker.ClientVersion() + "/containers/json").
Reply(http.StatusOK).
JSON(running)
// Run test
err := Run(context.Background(), fsys, []string{}, false)
// Check error
Expand Down

0 comments on commit b0f1399

Please sign in to comment.