MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / _write

Method _write

lib/sqlalchemy/testing/profiling.py:217–228  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

215 profile_f.close()
216
217 def _write(self):
218 print("Writing profile file %s" % self.fname)
219 profile_f = open(self.fname, "w")
220 profile_f.write(self._header())
221 for test_key in sorted(self.data):
222 per_fn = self.data[test_key]
223 profile_f.write("\n# TEST: %s\n\n" % test_key)
224 for platform_key in sorted(per_fn):
225 per_platform = per_fn[platform_key]
226 c = ",".join(str(count) for count in per_platform["counts"])
227 profile_f.write("%s %s %s\n" % (test_key, platform_key, c))
228 profile_f.close()
229
230
231def function_call_count(variance=0.05, times=1, warmup=0):

Callers 3

__init__Method · 0.95
resultMethod · 0.95
replaceMethod · 0.95

Calls 5

_headerMethod · 0.95
openFunction · 0.85
writeMethod · 0.45
joinMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected