MCPcopy Index your code
hub / github.com/RustPython/RustPython / create_file

Method create_file

Lib/test/audiotests.py:55–61  ·  view source on GitHub ↗
(self, testfile)

Source from the content-addressed store, hash-verified

53class AudioWriteTests(AudioTests):
54
55 def create_file(self, testfile):
56 f = self.fout = self.module.open(testfile, 'wb')
57 f.setnchannels(self.nchannels)
58 f.setsampwidth(self.sampwidth)
59 f.setframerate(self.framerate)
60 f.setcomptype(self.comptype, self.compname)
61 return f
62
63 def check_file(self, testfile, nframes, frames):
64 with self.module.open(testfile, 'rb') as f:

Callers 12

test_write_paramsMethod · 0.95
test_writeMethod · 0.95
test_write_bytearrayMethod · 0.95
test_write_arrayMethod · 0.95
test_write_memoryviewMethod · 0.95
test_multiple_writesMethod · 0.95
test_overflowed_writeMethod · 0.95
test_unseekable_readMethod · 0.95
test_unseekable_writeMethod · 0.95

Calls 5

setnchannelsMethod · 0.80
setsampwidthMethod · 0.80
setframerateMethod · 0.80
setcomptypeMethod · 0.80
openMethod · 0.45

Tested by

no test coverage detected