MCPcopy Create free account
hub / github.com/nodejs/node / with_fake_rdb

Method with_fake_rdb

deps/v8/tools/testrunner/utils/test_utils.py:239–255  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

237
238 @contextmanager
239 def with_fake_rdb(self):
240 records = []
241
242 def fake_sink():
243 return True
244
245 class Fake_RPC:
246
247 def __init__(self, sink):
248 pass
249
250 def send(self, r):
251 records.append(r)
252
253 with patch('testrunner.testproc.progress.rdb_sink', fake_sink), \
254 patch('testrunner.testproc.resultdb.ResultDB_RPC', Fake_RPC):
255 yield records
256
257
258class FakeOSContext(DefaultOSContext):

Callers 1

testRDBMethod · 0.80

Calls 1

patchFunction · 0.85

Tested by

no test coverage detected