/external/python/mock/mock/tests/ |
D | testmock.py | 16 MagicMock, Mock, NonCallableMock, 76 mock = Mock() 81 self.assertTrue(is_instance(mock.return_value, Mock), 104 mock = Mock(return_value=None) 110 mock = Mock(name='foo') 114 mocks = [(Mock(), 'mock'), (Mock(name='bar'), 'bar')] 129 mock = Mock(spec=X) 132 mock = Mock(spec=X()) 135 mock = Mock(spec_set=X) 138 mock = Mock(spec_set=X()) [all …]
|
D | testmagicmethods.py | 21 from mock import Mock, MagicMock 29 mock = Mock() 32 mock.__getitem__ = Mock() 53 mock = Mock() 67 mock1 = Mock() 68 mock2 = Mock() 70 mock1.__iter__ = Mock(return_value=iter([])) 76 mock = Mock() 83 mock = Mock() 91 mock = Mock() [all …]
|
/external/python/cpython3/Lib/unittest/test/testmock/ |
D | testmock.py | 10 MagicMock, Mock, NonCallableMock, 52 mock = Mock() 57 self.assertTrue(is_instance(mock.return_value, Mock), 80 mock = Mock(return_value=None) 86 mock = Mock(name='foo') 90 mocks = [(Mock(), 'mock'), (Mock(name='bar'), 'bar')] 105 mock = Mock(spec=X) 108 mock = Mock(spec=X()) 111 mock = Mock(spec_set=X) 114 mock = Mock(spec_set=X()) [all …]
|
D | testsealable.py | 20 m = mock.Mock() 22 self.assertIsInstance(m.test, mock.Mock) 23 self.assertIsInstance(m.test(), mock.Mock) 24 self.assertIsInstance(m.test().test2(), mock.Mock) 27 m = mock.Mock() 36 m = mock.Mock() 43 m = mock.Mock() 51 m = mock.Mock() 59 m = mock.Mock() 67 m = mock.Mock(test_value=1) [all …]
|
D | testmagicmethods.py | 3 from unittest.mock import Mock, MagicMock, _magics 10 mock = Mock() 13 mock.__getitem__ = Mock() 34 mock = Mock() 48 mock1 = Mock() 49 mock2 = Mock() 51 mock1.__iter__ = Mock(return_value=iter([])) 57 mock = Mock() 64 mock = Mock() 71 mock = Mock() [all …]
|
/external/autotest/client/common_lib/cros/cfm/usb/ |
D | usb_port_manager_unittest.py | 16 host = mock.Mock() 17 host.get_board = mock.Mock(return_value='board: guado') 18 host.run = mock.Mock() 19 host.path_exists = mock.Mock(return_value=False) 31 host = mock.Mock() 32 host.get_board = mock.Mock(return_value='board: guado') 33 host.run = mock.Mock() 34 host.path_exists = mock.Mock(return_value=True) 44 host = mock.Mock() 45 host.get_board = mock.Mock(return_value='board: fizz') [all …]
|
/external/googletest/googlemock/test/ |
D | gmock_link_test.h | 210 class Mock: public Interface { 212 Mock() {} in Mock() function 225 GTEST_DISALLOW_COPY_AND_ASSIGN_(Mock); 248 Mock mock; in TEST() 256 Mock mock; in TEST() 265 Mock mock; in TEST() 273 Mock mock; in TEST() 282 Mock mock; in TEST() 291 Mock mock; in TEST() 300 Mock mock; in TEST() [all …]
|
D | gmock-nice-strict_test.cc | 40 class Mock { class 42 Mock() {} in Mock() function in Mock 47 GTEST_DISALLOW_COPY_AND_ASSIGN_(Mock); 187 EXPECT_TRUE(Mock::IsNaggy(&raw_foo)); in TEST() 188 EXPECT_FALSE(Mock::IsNice(&raw_foo)); in TEST() 189 EXPECT_FALSE(Mock::IsStrict(&raw_foo)); in TEST() 288 Mock::AllowLeak(leaked); in TEST() 300 NiceMock< ::Mock> nice; in TEST() 307 EXPECT_FALSE(Mock::IsNaggy(&nice_foo)); in TEST() 308 EXPECT_TRUE(Mock::IsNice(&nice_foo)); in TEST() [all …]
|
/external/google-breakpad/src/testing/test/ |
D | gmock_link_test.h | 205 class Mock: public Interface { 207 Mock() {} in Mock() function 220 GTEST_DISALLOW_COPY_AND_ASSIGN_(Mock); 243 Mock mock; in TEST() 251 Mock mock; in TEST() 260 Mock mock; in TEST() 268 Mock mock; in TEST() 277 Mock mock; in TEST() 286 Mock mock; in TEST() 295 Mock mock; in TEST() [all …]
|
/external/python/cpython3/Lib/test/test_asyncio/ |
D | test_selector_events.py | 27 self._ssock = mock.Mock() 28 self._csock = mock.Mock() 52 self.selector = mock.Mock() 58 m = mock.Mock() 59 self.loop.add_reader = mock.Mock() 72 m = mock.Mock() 73 self.loop._add_reader = mock.Mock() 75 self.loop._add_writer = mock.Mock() 76 self.loop._remove_reader = mock.Mock() 77 self.loop._remove_writer = mock.Mock() [all …]
|
D | test_proactor_events.py | 34 self.proactor = mock.Mock() 37 self.sock = mock.Mock(socket.socket) 77 tr.close = mock.Mock() 88 tr._fatal_error = mock.Mock() 99 tr._fatal_error = mock.Mock() 107 tr._fatal_error = mock.Mock() 116 tr._fatal_error = mock.Mock() 117 tr._force_close = mock.Mock() 126 tr._fatal_error = mock.Mock() 134 tr._loop_writing = mock.Mock() [all …]
|
/external/mockito/src/test/java/org/mockitousage/annotation/ |
D | AnnotationsTest.java | 11 import org.mockito.Mock; 33 @Mock List<?> list; 34 @Mock final Map<Integer, String> map = new HashMap<Integer, String>(); 38 @Mock List<?> listTwo; 77 @Mock(answer = Answers.RETURNS_MOCKS, name = "i have a name") IMethods namedAndReturningMocks; 78 @Mock(answer = Answers.RETURNS_DEFAULTS) IMethods returningDefaults; 79 @Mock(extraInterfaces = {List.class}) IMethods hasExtraInterfaces; 80 @Mock() IMethods noExtraConfig; 81 @Mock(stubOnly=true) IMethods stubOnly; 98 @Mock private IMethods mock; [all …]
|
/external/swiftshader/third_party/llvm-7.0/llvm/utils/unittest/googlemock/include/gmock/ |
D | gmock-generated-nice-strict.h | 85 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 93 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 98 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 104 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 111 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 118 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 126 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 135 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 144 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 153 ::testing::Mock::AllowUninterestingCalls( in NiceMock() [all …]
|
/external/chromium-trace/catapult/devil/devil/android/perf/ |
D | perf_control_test.py | 33 perf_control_object.SetScalingGovernor = mock.Mock() 34 perf_control_object._ForceAllCpusOnline = mock.Mock() 35 perf_control_object._SetScalingMaxFreqForCpus = mock.Mock() 36 perf_control_object._SetMaxGpuClock = mock.Mock() 42 mock_device = mock.Mock(spec=device_utils.DeviceUtils) 44 mock_device.adb = mock.Mock(spec=adb_wrapper.AdbWrapper) 47 mock_device.RunShellCommand = mock.Mock(side_effect=_ShellCommandHandler) 65 mock_device = mock.Mock(spec=device_utils.DeviceUtils) 67 mock_device.adb = mock.Mock(spec=adb_wrapper.AdbWrapper) 70 mock_device.RunShellCommand = mock.Mock(side_effect=_ShellCommandHandler) [all …]
|
/external/google-breakpad/src/testing/include/gmock/ |
D | gmock-generated-nice-strict.h | 73 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 81 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 86 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 92 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 99 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 106 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 114 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 123 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 132 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 141 ::testing::Mock::AllowUninterestingCalls( in NiceMock() [all …]
|
/external/androidplot/AndroidPlot-Core/src/test/java/com/androidplot/mock/ |
D | MockRectF.java | 21 import mockit.Mock; 33 @Mock 38 @Mock 46 @Mock 56 @Mock 68 @Mock 80 @Mock 85 @Mock 90 @Mock
|
D | MockCanvas.java | 6 import mockit.Mock; 14 @Mock 19 @Mock 24 @Mock 27 @Mock 32 @Mock
|
/external/googletest/googlemock/ |
D | README.md | 1 ## Google Mock ## 49 the Apache License, which is different from Google Mock's license. argument 57 Google Test, if you choose to use Google Mock with it (recommended). 58 * Read [Google Mock for Dummies](../googlemock/docs/ForDummies.md). 59 * Read the instructions below on how to build Google Mock. 61 You can also watch Zhanyong's [talk](http://www.youtube.com/watch?v=sYpCyLI47rM) on Google Mock's u… 77 ### Using Google Mock Without Google Test ### 79 Google Mock is not a testing framework itself. Instead, it needs a 80 testing framework for writing tests. Google Mock works seamlessly 86 Google Mock is implemented on top of [Google Test]( [all …]
|
/external/googletest/googlemock/include/gmock/ |
D | gmock-nice-strict.h | 75 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 88 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 96 ::testing::Mock::AllowUninterestingCalls( in NiceMock() 101 ::testing::Mock::UnregisterCallReaction( in ~NiceMock() 113 ::testing::Mock::WarnUninterestingCalls( in NaggyMock() 126 ::testing::Mock::WarnUninterestingCalls( in NaggyMock() 134 ::testing::Mock::WarnUninterestingCalls( in NaggyMock() 139 ::testing::Mock::UnregisterCallReaction( in ~NaggyMock() 151 ::testing::Mock::FailUninterestingCalls( in StrictMock() 164 ::testing::Mock::FailUninterestingCalls( in StrictMock() [all …]
|
/external/google-breakpad/src/testing/ |
D | README | 15 Google Mock: 38 License, which is different from Google Mock's license. 43 Google Mock is implemented on top of the Google Test C++ testing 46 must use the bundled version of Google Test when using Google Mock, or 49 You can also easily configure Google Mock to work with another testing 55 Google Mock depends on advanced C++ features and thus requires a more 56 modern compiler. The following are needed to use Google Mock: 60 These are the base requirements to build and use Google Mock from a source 81 build Google Mock and its own tests from an SVN checkout (described 93 There are two primary ways of getting Google Mock's source code: you [all …]
|
/external/python/cpython3/Lib/idlelib/idle_test/ |
D | test_squeezer.py | 7 from unittest.mock import Mock, NonCallableMagicMock, patch, sentinel, ANY 110 squeezer.get_line_width = Mock(return_value=80) 160 editwin.write = orig_write = Mock(return_value=SENTINEL_VALUE) 187 editwin.write = orig_write = Mock(return_value=SENTINEL_VALUE) 198 editwin.write = orig_write = Mock(return_value=SENTINEL_VALUE) 212 squeezer.count_lines = Mock(return_value=6) 225 squeezer.count_lines = Mock(return_value=6) 235 retval = squeezer.squeeze_current_text_event(event=Mock()) 243 squeezer.expandingbuttons[0].expand(event=Mock()) 252 squeezer.count_lines = Mock(return_value=6) [all …]
|
/external/grpc-grpc/src/csharp/Grpc.Examples.Tests/ |
D | MathClientMockableTest.cs | 36 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseBlockingUnaryCallCanBeMocked() 46 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseBlockingUnaryCallWithCallOptionsCallCanBeMocked() 56 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseAsyncUnaryCallCanBeMocked() 67 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseClientStreamingCallCanBeMocked() 68 var mockRequestStream = new Moq.Mock<IClientStreamWriter<Num>>(); in ClientBaseClientStreamingCallCanBeMocked() 79 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseServerStreamingCallCanBeMocked() 80 var mockResponseStream = new Moq.Mock<IAsyncStreamReader<Num>>(); in ClientBaseServerStreamingCallCanBeMocked() 91 var mockClient = new Moq.Mock<Math.MathClient>(); in ClientBaseDuplexStreamingCallCanBeMocked() 92 var mockRequestStream = new Moq.Mock<IClientStreamWriter<DivArgs>>(); in ClientBaseDuplexStreamingCallCanBeMocked() 93 var mockResponseStream = new Moq.Mock<IAsyncStreamReader<DivReply>>(); in ClientBaseDuplexStreamingCallCanBeMocked()
|
/external/python/oauth2client/tests/contrib/django_util/ |
D | test_django_storage.py | 64 filter_mock = mock.Mock(return_value=entities) 65 object_mock = mock.Mock() 78 filter_mock = mock.Mock(return_value=entities) 79 object_mock = mock.Mock() 94 filter_mock = mock.Mock(return_value=entities) 95 object_mock = mock.Mock() 107 entity_mock = mock.Mock(credentials=None) 108 objects = mock.Mock( 109 get_or_create=mock.Mock(return_value=(entity_mock, None))) 127 filter_mock = mock.Mock(return_value=entities) [all …]
|
/external/libchrome/base/threading/ |
D | scoped_blocking_call_unittest.cc | 51 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 58 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 65 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 70 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 79 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 89 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 99 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 109 testing::Mock::VerifyAndClear(&observer_); in TEST_F() 114 testing::Mock::VerifyAndClear(&observer_); in TEST_F()
|
/external/chromium-trace/catapult/devil/devil/android/ |
D | md5sum_test.py | 30 mock.Mock(side_effect=lambda a, device=None: mocked_attrs[a])), 32 new=mock.Mock(return_value=True)), 43 mock_get_cmd_output = mock.Mock( 57 mock_get_cmd_output = mock.Mock( 76 mock_get_cmd_output = mock.Mock( 94 device.RunShellCommand = mock.Mock(side_effect=Exception()) 107 device.RunShellCommand = mock.Mock(return_value=device_md5sum_output) 127 device.RunShellCommand = mock.Mock(return_value=device_md5sum_output) 151 device.RunShellCommand = mock.Mock(return_value=device_md5sum_output) 176 device.RunShellCommand = mock.Mock(return_value=device_md5sum_output) [all …]
|