Skip to content

Commit

Permalink
Merge pull request #62 from itchyny/fix-underscore-names
Browse files Browse the repository at this point in the history
Fix underscore names in tests
  • Loading branch information
mattn committed Mar 23, 2022
2 parents 4190c90 + 011b00b commit f9d5553
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions runewidth_posix_test.go
Expand Up @@ -9,22 +9,22 @@ import (
)

type envVars struct {
lang string
lc_all string
lc_ctype string
lang string
lcall string
lcctype string
}

func saveEnv() envVars {
return envVars{
lang: os.Getenv("LANG"),
lc_all: os.Getenv("LC_ALL"),
lc_ctype: os.Getenv("LC_CTYPE"),
lang: os.Getenv("LANG"),
lcall: os.Getenv("LC_ALL"),
lcctype: os.Getenv("LC_CTYPE"),
}
}
func restoreEnv(env *envVars) {
os.Setenv("LANG", env.lang)
os.Setenv("LC_ALL", env.lc_all)
os.Setenv("LC_CTYPE", env.lc_ctype)
os.Setenv("LC_ALL", env.lcall)
os.Setenv("LC_CTYPE", env.lcctype)
}

func TestIsEastAsian(t *testing.T) {
Expand Down

0 comments on commit f9d5553

Please sign in to comment.