44 source : |
55 import("path")
66
7- str p = path.TEMPFILE ("prefix-writefile-ansi.txt")
7+ str p = path.temp_file ("prefix-writefile-ansi.txt")
88
99 assert(write_file("Prefix", p, coding = "ANSI"))
1010 assert(eq(read_file(p, coding = "ANSI"), "Prefix"))
@@ -14,7 +14,7 @@ passing:
1414 source : |
1515 import("path")
1616
17- str p = path.TEMPFILE ("prefix-writefile-bin.bin")
17+ str p = path.temp_file ("prefix-writefile-bin.bin")
1818
1919 assert(write_file("0100000101111010", p, coding = "bin"))
2020 assert(eq(read_file(p, coding = "bin"), "0100000101111010"))
@@ -25,7 +25,7 @@ passing:
2525 source : |
2626 import("path")
2727
28- str p = path.TEMPFILE ("prefix-writefile-binary.bin")
28+ str p = path.temp_file ("prefix-writefile-binary.bin")
2929
3030 assert(write_file("0100000101111010", p, coding = "binary"))
3131 assert(eq(read_file(p, coding = "binary"), "0100000101111010"))
@@ -36,10 +36,10 @@ passing:
3636 source : |
3737 import("path")
3838
39- str d = path.TEMPFILE ("prefix-writefile-fail-dir")
39+ str d = path.temp_file ("prefix-writefile-fail-dir")
4040
4141 if(eq(os(),"win")){
42- assert(eq(cl(join("powershell -NoProfile -NonInteractive -Command \"New-Item -ItemType Directory -Force -Path '", path.WINPATH (d), "'\"")), 0d0))
42+ assert(eq(cl(join("powershell -NoProfile -NonInteractive -Command \"New-Item -ItemType Directory -Force -Path '", path.windows_path (d), "'\"")), 0d0))
4343 } else {
4444 assert(eq(cl(join("mkdir -p ", d)), 0d0))
4545 }
@@ -51,7 +51,7 @@ passing:
5151 source : |
5252 import("path")
5353
54- str p = path.TEMPFILE ("prefix-writefile-hex.bin")
54+ str p = path.temp_file ("prefix-writefile-hex.bin")
5555
5656 assert(write_file("507265666978", p, coding = "hex"))
5757 assert(eq(read_file(p), "Prefix"))
@@ -62,7 +62,7 @@ passing:
6262 source : |
6363 import("path")
6464
65- str p = path.TEMPFILE ("prefix-writefile-utf16-be.txt")
65+ str p = path.temp_file ("prefix-writefile-utf16-be.txt")
6666
6767 assert(write_file("Prefix", p, coding = "UTF-16 BE"))
6868 assert(eq(read_file(p, coding = "UTF-16 BE"), "Prefix"))
@@ -72,7 +72,7 @@ passing:
7272 source : |
7373 import("path")
7474
75- str p = path.TEMPFILE ("prefix-writefile-utf16-le.txt")
75+ str p = path.temp_file ("prefix-writefile-utf16-le.txt")
7676
7777 assert(write_file("Prefix", p, coding = "UTF-16 LE"))
7878 assert(eq(read_file(p, coding = "UTF-16 LE"), "Prefix"))
@@ -82,7 +82,7 @@ passing:
8282 source : |
8383 import("path")
8484
85- str p = path.TEMPFILE ("prefix-writefile-utf8-bom.txt")
85+ str p = path.temp_file ("prefix-writefile-utf8-bom.txt")
8686
8787 assert(write_file("Prefix", p, coding = "UTF-8 BOM"))
8888 assert(eq(read_file(p), "Prefix"))
@@ -93,7 +93,7 @@ passing:
9393 source : |
9494 import("path")
9595
96- str p = path.TEMPFILE ("prefix-writefile-utf8.txt")
96+ str p = path.temp_file ("prefix-writefile-utf8.txt")
9797
9898 assert(write_file("Prefix", p))
9999 assert(eq(read_file(p), "Prefix"))
@@ -105,7 +105,7 @@ failing:
105105 source : |
106106 import("path")
107107
108- str p = path.TEMPFILE ("prefix-writefile-bad-binary2.txt")
108+ str p = path.temp_file ("prefix-writefile-bad-binary2.txt")
109109
110110 write_file("010a0101", p, coding = "binary")
111111
@@ -114,7 +114,7 @@ failing:
114114 source : |
115115 import("path")
116116
117- str p = path.TEMPFILE ("prefix-writefile-bad-binary.txt")
117+ str p = path.temp_file ("prefix-writefile-bad-binary.txt")
118118
119119 write_file("101", p, coding = "binary")
120120
@@ -123,7 +123,7 @@ failing:
123123 source : |
124124 import("path")
125125
126- str p = path.TEMPFILE ("prefix-writefile-bad-hex.txt")
126+ str p = path.temp_file ("prefix-writefile-bad-hex.txt")
127127
128128 write_file("abc", p, coding = "hex")
129129
@@ -132,7 +132,7 @@ failing:
132132 source : |
133133 import("path")
134134
135- str p = path.TEMPFILE ("prefix-writefile-unsupported.txt")
135+ str p = path.temp_file ("prefix-writefile-unsupported.txt")
136136
137137 write_file("Prefix", p, coding = "UTF-7")
138138
0 commit comments