diff --git a/tests/test-encode b/tests/test-encode
index 6134adc1c431b67d9192c00f2842cc04dfffc337_dGVzdHMvdGVzdC1lbmNvZGU=..21b3346ce3c7b6b1ee2d996bc952f6bd298be367_dGVzdHMvdGVzdC1lbmNvZGU= 100755
--- a/tests/test-encode
+++ b/tests/test-encode
@@ -4,7 +4,7 @@
 
 cat > .hg/hgrc <<EOF
 [encode]
-not.gz = tr a-z A-Z
+not.gz = tr [:lower:] [:upper:]
 *.gz = gzip -d
 
 [decode]
@@ -8,7 +8,7 @@
 *.gz = gzip -d
 
 [decode]
-not.gz = tr A-Z a-z
+not.gz = tr [:upper:] [:lower:]
 *.gz = gzip
 
 EOF