File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -2,11 +2,13 @@ package app
2
2
3
3
import (
4
4
"claude-squad/config"
5
+ "claude-squad/log"
5
6
"claude-squad/session"
6
7
"claude-squad/ui"
7
8
"claude-squad/ui/overlay"
8
9
"context"
9
10
"fmt"
11
+ "os"
10
12
"testing"
11
13
12
14
"github.com/charmbracelet/bubbles/spinner"
@@ -15,6 +17,19 @@ import (
15
17
"github.com/stretchr/testify/require"
16
18
)
17
19
20
+ // TestMain runs before all tests to set up the test environment
21
+ func TestMain (m * testing.M ) {
22
+ // Initialize the logger before any tests run
23
+ log .Initialize (false )
24
+ defer log .Close ()
25
+
26
+ // Run all tests
27
+ exitCode := m .Run ()
28
+
29
+ // Exit with the same code as the tests
30
+ os .Exit (exitCode )
31
+ }
32
+
18
33
// TestConfirmationModalStateTransitions tests state transitions without full instance setup
19
34
func TestConfirmationModalStateTransitions (t * testing.T ) {
20
35
// Create a minimal home struct for testing state transitions
You can’t perform that action at this time.
0 commit comments