Home
last modified time | relevance | path

Searched refs:tempfile (Results 1 – 25 of 1193) sorted by relevance

12345678910>>...48

/external/rust/crates/tokio/tests/
Dfs_file.rs9 use tempfile::NamedTempFile;
15 let mut tempfile = tempfile(); in basic_read() localVariable
16 tempfile.write_all(HELLO).unwrap(); in basic_read()
18 let mut file = File::open(tempfile.path()).await.unwrap(); in basic_read()
29 let tempfile = tempfile(); in basic_write() localVariable
31 let mut file = File::create(tempfile.path()).await.unwrap(); in basic_write()
36 let file = std::fs::read(tempfile.path()).unwrap(); in basic_write()
42 let tempfile = tempfile(); in basic_write_and_shutdown() localVariable
44 let mut file = File::create(tempfile.path()).await.unwrap(); in basic_write_and_shutdown()
49 let file = std::fs::read(tempfile.path()).unwrap(); in basic_write_and_shutdown()
[all …]
/external/ltp/testcases/kernel/fs/stream/
Dstream05.c52 char tempfile[40] = ""; variable
73 sprintf(tempfile, "stream05.%d", getpid()); in main()
76 if ((stream = fopen(tempfile, "a+")) == NULL) { in main()
78 tempfile, in main()
84 if ((stream = fopen(tempfile, "r+")) == NULL) { in main()
86 tempfile, in main()
135 if ((stream = fopen(tempfile, "r+")) == NULL) { in main()
137 tempfile, in main()
182 if ((stream = fopen(tempfile, "rb")) == NULL) { in main()
184 tempfile, in main()
[all …]
/external/python/cpython3/Lib/test/
Dtest_tempfile.py2 import tempfile
21 has_textmode = (tempfile._text_openflags != tempfile._bin_openflags)
37 self.assertIs(str, tempfile._infer_return_type(''))
38 self.assertIs(bytes, tempfile._infer_return_type(b''))
39 self.assertIs(str, tempfile._infer_return_type(None))
42 self.assertIs(str, tempfile._infer_return_type('', ''))
43 self.assertIs(bytes, tempfile._infer_return_type(b'', b''))
45 tempfile._infer_return_type('', b'')
47 tempfile._infer_return_type(b'', '')
50 self.assertIs(str, tempfile._infer_return_type(None, ''))
[all …]
/external/python/cpython2/Lib/test/
Dtest_tempfile.py2 import tempfile
26 has_textmode = (tempfile._text_openflags != tempfile._bin_openflags)
73 dict = tempfile.__dict__
103 self.r = tempfile._RandomNameSequence()
181 cand = tempfile._candidate_tempdir_list()
197 cand = tempfile._candidate_tempdir_list()
223 our_temp_directory = tempfile.mkdtemp()
229 with support.swap_attr(tempfile, "_candidate_tempdir_list",
232 tempfile._get_default_tempdir()
241 tempfile._get_default_tempdir()
[all …]
/external/autotest/client/common_lib/
Dseven_unittest.py11 import tempfile
21 os.remove(self.tempfile)
28 with tempfile.NamedTemporaryFile(delete=False) as fh:
29 self.tempfile = fh.name
39 with open(self.tempfile, "wb") as fh:
44 filename=self.tempfile,
55 with open(self.tempfile, "wb") as fh:
60 filename=self.tempfile,
74 with open(self.tempfile, "wb") as fh:
79 filename=self.tempfile,
Dtest_unittest.py12 import tempfile
46 self.crash_reporter_dir = tempfile.mkdtemp()
217 self.test.resultsdir = tempfile.mkdtemp()
227 self.test.resultsdir = tempfile.mkdtemp()
240 self.test.resultsdir = tempfile.mkdtemp()
253 self.test.resultsdir = tempfile.mkdtemp()
268 self.test.resultsdir = tempfile.mkdtemp()
281 self.test.resultsdir = tempfile.mkdtemp()
295 self.test.resultsdir = tempfile.mkdtemp()
309 self.test.resultsdir = tempfile.mkdtemp()
[all …]
/external/python/pyfakefs/pyfakefs/tests/
Dfake_tempfile_test.py21 import tempfile
34 obj = tempfile.NamedTemporaryFile()
40 obj = tempfile.NamedTemporaryFile(delete=False)
46 obj = tempfile.NamedTemporaryFile(mode='w', delete=False)
54 temporary = tempfile.mkstemp()
58 os.path.join(tempfile.gettempdir(), 'tmp')))
70 self.assertRaises(OSError, tempfile.mkstemp, dir='/dir')
74 temporary = tempfile.mkstemp(dir='/dir')
85 dirname = tempfile.mkdtemp()
92 with tempfile.TemporaryDirectory() as tmpdir:
[all …]
/external/parameter-framework/upstream/test/functional-tests-legacy/PfwTestCase/Domains/
DtDomain_creation_deletion.py282 tempfile = open("tempfile", "w")
283 tempfile.write(out)
284 tempfile.close()
287 tempfile = open("tempfile", "r")
289 line=tempfile.readline()
291 line=tempfile.readline()
293 tempfile.close()
295 tempfile = open("tempfile", "r")
299 domain_created = tempfile.readline().strip('\n\r'),
302 domain_created = tempfile.readline()
[all …]
/external/ltp/testcases/kernel/syscalls/open/
Dopen09.c38 static char tempfile[40] = ""; variable
57 fildes = open(tempfile, O_WRONLY); in main()
69 fildes = open(tempfile, O_RDONLY); in main()
94 sprintf(tempfile, "open09.%d", getpid()); in setup()
96 fildes = creat(tempfile, 0600); in setup()
99 tempfile); in setup()
107 unlink(tempfile); in cleanup()
/external/rust/crates/nix/test/sys/
Dtest_ioctl.rs167 use tempfile::tempfile;
176 let file = tempfile().unwrap(); in test_ioctl_none_bad()
184 let file = tempfile().unwrap(); in test_ioctl_read_bad()
193 let file = tempfile().unwrap(); in test_ioctl_write_int_bad()
201 let file = tempfile().unwrap(); in test_ioctl_write_ptr_bad()
213 let file = tempfile().unwrap(); in test_ioctl_none()
231 let file = tempfile().unwrap(); in test_ioctl_write_ptr()
243 let file = tempfile().unwrap(); in test_ioctl_write_int()
252 let file = tempfile().unwrap(); in test_ioctl_read()
262 let file = tempfile().unwrap(); in test_ioctl_readwrite()
[all …]
Dtest_aio.rs13 use tempfile::tempfile;
54 let f = tempfile().unwrap(); in test_cancel()
79 let f = tempfile().unwrap(); in test_aio_cancel_all()
102 let mut f = tempfile().unwrap(); in test_fsync()
125 let mut f = tempfile().unwrap(); in test_fsync_error()
149 let mut f = tempfile().unwrap(); in test_aio_suspend()
195 let mut f = tempfile().unwrap(); in test_read()
223 let mut f = tempfile().unwrap(); in test_read_error()
241 let mut f = tempfile().unwrap(); in test_read_into_mut_slice()
267 let mut f = tempfile().unwrap(); in test_read_into_pointer()
[all …]
/external/tensorflow/tensorflow/lite/schema/
Dupgrade_schema_test.py22 import tempfile
257 non_existent = tempfile.mktemp(suffix=".json")
263 invalid_extension = tempfile.mktemp(suffix=".foo")
266 with tempfile.NamedTemporaryFile(suffix=".json", mode="w+") as in_json:
279 with tempfile.NamedTemporaryFile(suffix=".json", mode="w+") as in_json, \
280 tempfile.NamedTemporaryFile(
282 tempfile.NamedTemporaryFile(
284 tempfile.NamedTemporaryFile(
/external/pigweed/pw_build/py/
Dzip_test.py18 import tempfile
83 with tempfile.TemporaryDirectory() as tmp_dir:
102 with tempfile.TemporaryDirectory() as tmp_dir:
126 with tempfile.TemporaryDirectory() as tmp_dir:
146 with tempfile.TemporaryDirectory() as tmp_dir:
166 with tempfile.TemporaryDirectory() as tmp_dir:
190 with tempfile.TemporaryDirectory() as tmp_dir:
210 with tempfile.TemporaryDirectory() as tmp_dir:
233 with tempfile.TemporaryDirectory() as tmp_dir:
243 with tempfile.TemporaryDirectory() as tmp_dir:
/external/crosvm/disk/src/
Dcomposite.rs347 use tempfile::tempfile;
351 let file1 = tempfile().unwrap(); in block_duplicate_offset_disks()
352 let file2 = tempfile().unwrap(); in block_duplicate_offset_disks()
368 let file1 = tempfile().unwrap(); in get_len()
369 let file2 = tempfile().unwrap(); in get_len()
387 let file = tempfile().unwrap(); in single_file_passthrough()
409 let file1 = tempfile().unwrap(); in triple_file_fds()
410 let file2 = tempfile().unwrap(); in triple_file_fds()
411 let file3 = tempfile().unwrap(); in triple_file_fds()
441 let file1 = tempfile().unwrap(); in triple_file_passthrough()
[all …]
/external/llvm/utils/release/
Dmerge.sh76 tempfile=`mktemp /tmp/merge.XXXXXX` || exit 1
79 echo "Reverting r$rev:" > $tempfile
81 echo "Merging r$rev:" > $tempfile
83 svn log -c $rev http://llvm.org/svn/llvm-project/$proj/trunk >> $tempfile 2>&1
99 echo svn commit -F $tempfile
/external/python/pyfakefs/pyfakefs/pytest_tests/
Dpytest_plugin_test.py3 import tempfile
14 fake_temp_file = tempfile.NamedTemporaryFile()
20 real_temp_file = tempfile.NamedTemporaryFile()
29 fake_temp_file = tempfile.NamedTemporaryFile()
35 real_temp_file = tempfile.NamedTemporaryFile()
/external/tensorflow/tensorflow/lite/micro/tools/make/
Ddownload_and_extract.sh118 local tempfile=${tempdir}/temp_file
138 curl -LsS --fail --retry 5 "${url}" > ${tempfile}
156 DOWNLOADED_MD5=$(openssl dgst -md5 ${tempfile} | sed 's/.* //g')
166 tar -C "${dir}" --strip-components=1 -xzf ${tempfile}
168 tar -C "${dir}" --strip-components=1 -xf ${tempfile}
171 tar -C "${dir}" --strip-components=1 -xjf ${tempfile}
173 unzip ${tempfile} -d ${tempdir2} 2>&1 1>/dev/null
/external/toolchain-utils/afdo_tools/bisection/
Dafdo_prof_analysis_e2e_test.py14 import tempfile
89 temp_dir = tempfile.mkdtemp()
99 fd_first, first_result = tempfile.mkstemp(dir=temp_dir)
101 fd_state, state_file = tempfile.mkstemp(dir=temp_dir)
110 fd_second, second_result = tempfile.mkstemp(dir=temp_dir)
128 temp_dir = tempfile.mkdtemp()
131 fd_state, state_file = tempfile.mkstemp(dir=temp_dir)
236 temp_dir = tempfile.mkdtemp()
/external/rust/crates/nix/test/
Dtest_stat.rs45 use tempfile;
98 let tempdir = tempfile::tempdir().unwrap(); in test_stat_and_fstat()
112 let tempdir = tempfile::tempdir().unwrap(); in test_fstatat()
130 let tempdir = tempfile::tempdir().unwrap(); in test_stat_fstat_lstat()
152 let tempdir = tempfile::tempdir().unwrap(); in test_fchmod()
176 let tempdir = tempfile::tempdir().unwrap(); in test_fchmodat()
218 let tempdir = tempfile::tempdir().unwrap(); in test_utimes()
234 let tempdir = tempfile::tempdir().unwrap(); in test_lutimes()
254 let tempdir = tempfile::tempdir().unwrap(); in test_futimens()
268 let tempdir = tempfile::tempdir().unwrap(); in test_utimensat()
[all …]
/external/libcups/cups/
Dppd-util.c140 char tempfile[1024] = ""; /* Temporary filename */ in cupsGetPPD3() local
392 fd = cupsTempFd(tempfile, sizeof(tempfile)); in cupsGetPPD3()
430 if (tempfile[0]) in cupsGetPPD3()
431 strlcpy(buffer, tempfile, bufsize); in cupsGetPPD3()
439 else if (tempfile[0]) in cupsGetPPD3()
440 unlink(tempfile); in cupsGetPPD3()
442 else if (tempfile[0]) in cupsGetPPD3()
443 unlink(tempfile); in cupsGetPPD3()
/external/expat/
Dfix-xmltest-log.sh37 tempfile="$(mktemp)"
47 "${filename}" > "${tempfile}"
48 mv "${tempfile}" "${filename}"
/external/oss-fuzz/infra/cifuzz/
Drun_fuzzers_test.py18 import tempfile
136 with tempfile.TemporaryDirectory() as tmp_dir:
149 with tempfile.TemporaryDirectory() as tmp_dir:
156 with tempfile.TemporaryDirectory() as tmp_dir:
169 with tempfile.TemporaryDirectory() as tmp_dir:
187 with tempfile.TemporaryDirectory() as tmp_dir:
202 with tempfile.TemporaryDirectory() as tmp_dir:
212 with tempfile.TemporaryDirectory() as tmp_dir:
336 with tempfile.TemporaryDirectory() as tmp_dir:
356 with tempfile.TemporaryDirectory() as tmp_dir:
[all …]
/external/tensorflow/tensorflow/lite/toco/python/
Dtoco_from_protos_test.py20 import tempfile
60 with tempfile.NamedTemporaryFile() as fp_toco, \
61 tempfile.NamedTemporaryFile() as fp_model, \
62 tempfile.NamedTemporaryFile() as fp_input, \
63 tempfile.NamedTemporaryFile() as fp_output:
/external/autotest/site_utils/lxc/
Dlxc_config_unittest.py9 import tempfile
48 'source': tempfile.mkdtemp(dir=tmpdir),
55 'source': tempfile.mkdtemp(dir=tmpdir),
106 self.rootfs = tempfile.mkdtemp()
165 with tempfile.NamedTemporaryFile() as tmp:
/external/autotest/client/cros/
Dtpm_store.py5 import tempfile
51 pem_file = tempfile.NamedTemporaryFile()
54 der_file = tempfile.NamedTemporaryFile()
66 self._directory = tempfile.mkdtemp()

12345678910>>...48