Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: tinygo-org/tinygo
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: d281f2252e4a32d3e6ee9bc2075769b97647d94c
Choose a base ref
..
head repository: tinygo-org/tinygo
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 523bdeb43b865e43fdb186edce876ffc66f20275
Choose a head ref
Showing with 5 additions and 4 deletions.
  1. +5 −4 tests/testing/chdir/chdir.go
9 changes: 5 additions & 4 deletions tests/testing/chdir/chdir.go
Original file line number Diff line number Diff line change
@@ -14,16 +14,17 @@ argument.
*/
func main() {
expectDir := os.Getenv("EXPECT_DIR")
expectDir, err := filepath.EvalSymlinks(expectDir)
if err != nil {
log.Fatal(err)
}
cwd, err := os.Getwd()
if err != nil {
log.Fatal(err)
}
if runtime.GOOS == "windows" {
cwd = filepath.ToSlash(cwd)
} else {
expectDir, err = filepath.EvalSymlinks(expectDir)
if err != nil {
log.Fatal(err)
}
}
if cwd != expectDir {
log.Fatalf("expected:\"%v\" != os.Getwd():\"%v\"", expectDir, cwd)