Skip to content

Commit

Permalink
test: Move the testing proxy variables for the color mod to a separat…
Browse files Browse the repository at this point in the history
…e file
  • Loading branch information
Dobefu committed Feb 4, 2025
1 parent 0bce83e commit 94022e6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 0 additions & 2 deletions cmd/color/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@ const (
BgWhite
)

var osStatFn = os.Stdout.Stat

func SprintColor(fg Color, bg Color, message string) string {
fileInfo, _ := osStatFn()

Expand Down
5 changes: 5 additions & 0 deletions cmd/color/test_utils.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package color

import "os"

var osStatFn = os.Stdout.Stat

0 comments on commit 94022e6

Please sign in to comment.