We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6c7fd57 commit 6cf9524Copy full SHA for 6cf9524
cli/format_test.go
@@ -568,6 +568,15 @@ go/main.go
568
func TestDeterministicOrderingInPipeline(t *testing.T) {
569
as := require.New(t)
570
571
+ // capture current cwd, so we can replace it after the test is finished
572
+ cwd, err := os.Getwd()
573
+ as.NoError(err)
574
+
575
+ t.Cleanup(func() {
576
+ // return to the previous working directory
577
+ as.NoError(os.Chdir(cwd))
578
+ })
579
580
tempDir := test.TempExamples(t)
581
configPath := tempDir + "/treefmt.toml"
582
@@ -595,7 +604,7 @@ func TestDeterministicOrderingInPipeline(t *testing.T) {
595
604
},
596
605
})
597
606
598
- _, err := cmd(t, "-C", tempDir)
607
+ _, err = cmd(t, "-C", tempDir)
599
608
as.NoError(err)
600
609
601
610
matcher := regexp.MustCompile("^fmt-(.*)")
0 commit comments