Home
last modified time | relevance | path

Searched refs:mock (Results 1 – 25 of 121) sorted by relevance

12345

/external/chromium/testing/gmock/test/
Dgmock_link_test.h243 Mock mock; in TEST() local
245 EXPECT_CALL(mock, VoidFromString(_)).WillOnce(Return()); in TEST()
246 mock.VoidFromString(NULL); in TEST()
251 Mock mock; in TEST() local
254 EXPECT_CALL(mock, StringFromString(_)).WillOnce(Return(&ch)); in TEST()
255 mock.StringFromString(NULL); in TEST()
260 Mock mock; in TEST() local
262 EXPECT_CALL(mock, VoidFromString(_)).WillOnce(Return()); in TEST()
263 mock.VoidFromString(NULL); in TEST()
268 Mock mock; in TEST() local
[all …]
Dgmock-generated-function-mockers_test.cc371 MockStack<int> mock; in TEST() local
373 EXPECT_CALL(mock, GetSize()) in TEST()
377 EXPECT_CALL(mock, Push(_)); in TEST()
379 EXPECT_CALL(mock, GetTop()) in TEST()
381 EXPECT_CALL(mock, Pop()) in TEST()
384 EXPECT_EQ(0, mock.GetSize()); in TEST()
385 mock.Push(5); in TEST()
386 EXPECT_EQ(1, mock.GetSize()); in TEST()
387 EXPECT_EQ(5, mock.GetTop()); in TEST()
388 mock.Pop(); in TEST()
[all …]
Dgmock_output_test_golden.txt33 Unexpected mock function call - returning default value.
47 Unexpected mock function call - returning directly.
75 Uninteresting mock function call - returning default value.
83 Uninteresting mock function call - returning directly.
90 Unexpected mock function call - returning default value.
111 Unexpected mock function call - returning default value.
132 Unexpected mock function call - returning default value.
171 Unexpected mock function call - returning default value.
187 Unexpected mock function call - returning default value.
201 Unexpected mock function call - returning default value.
[all …]
Dgmock-actions_test.cc630 MockClass mock; in TEST() local
631 EXPECT_CALL(mock, IntFunc(_)) in TEST()
633 EXPECT_EQ(0, mock.IntFunc(true)); in TEST()
639 MockClass mock; in TEST() local
640 EXPECT_CALL(mock, Foo()) in TEST()
643 mock.Foo(); in TEST()
653 MockClass mock; in TEST() local
654 EXPECT_CALL(mock, IntFunc(_)) in TEST()
663 mock.IntFunc(true); in TEST()
671 MockClass mock; in TEST() local
[all …]
Dgmock-internal-utils_test.cc521 DummyMock mock; in ExpectCallLogger() local
522 EXPECT_CALL(mock, TestMethod()); in ExpectCallLogger()
523 mock.TestMethod(); in ExpectCallLogger()
545 DummyMock mock; in OnCallLogger() local
546 ON_CALL(mock, TestMethod()); in OnCallLogger()
568 DummyMock mock; in OnCallAnyArgumentLogger() local
569 ON_CALL(mock, TestMethodArg(_)); in OnCallAnyArgumentLogger()
/external/chromium/base/
Dgmock_unittest.cc68 MockSampleClass mock; in TEST() local
70 EXPECT_CALL(mock, ReturnSomething()) in TEST()
74 EXPECT_EQ(1, mock.ReturnSomething()); in TEST()
75 EXPECT_EQ(2, mock.ReturnSomething()); in TEST()
76 EXPECT_EQ(3, mock.ReturnSomething()); in TEST()
78 EXPECT_CALL(mock, ReturnNothingConstly()).Times(2); in TEST()
79 mock.ReturnNothingConstly(); in TEST()
80 mock.ReturnNothingConstly(); in TEST()
85 MockSampleClass mock; in TEST() local
87 EXPECT_CALL(mock, OutputParam(_)) in TEST()
[all …]
/external/webkit/Source/WebKit/chromium/tests/
DCCThreadTaskTest.cpp48 Mock mock; in TEST() local
49 EXPECT_CALL(mock, method0()).Times(1); in TEST()
50 EXPECT_CALL(mock, method1(9)).Times(1); in TEST()
51 EXPECT_CALL(mock, method2(9, 8)).Times(1); in TEST()
52 EXPECT_CALL(mock, method3(9, 8, 7)).Times(1); in TEST()
53 EXPECT_CALL(mock, method4(9, 8, 7, 6)).Times(1); in TEST()
55 createCCThreadTask(&mock, &Mock::method0)->performTask(); in TEST()
56 createCCThreadTask(&mock, &Mock::method1, 9)->performTask(); in TEST()
57 createCCThreadTask(&mock, &Mock::method2, 9, 8)->performTask(); in TEST()
58 createCCThreadTask(&mock, &Mock::method3, 9, 8, 7)->performTask(); in TEST()
[all …]
/external/chromium/chrome/browser/policy/
Ddevice_management_service_unittest.cc105 DeviceRegisterResponseDelegateMock mock; in TEST_P() local
106 EXPECT_CALL(mock, OnError(GetParam().expected_error_)); in TEST_P()
108 backend_->ProcessRegisterRequest(kAuthToken, kDeviceId, request, &mock); in TEST_P()
121 DeviceUnregisterResponseDelegateMock mock; in TEST_P() local
122 EXPECT_CALL(mock, OnError(GetParam().expected_error_)); in TEST_P()
124 backend_->ProcessUnregisterRequest(kDMToken, kDeviceId, request, &mock); in TEST_P()
137 DevicePolicyResponseDelegateMock mock; in TEST_P() local
138 EXPECT_CALL(mock, OnError(GetParam().expected_error_)); in TEST_P()
144 backend_->ProcessPolicyRequest(kDMToken, kDeviceId, request, &mock); in TEST_P()
289 DeviceRegisterResponseDelegateMock mock; in TEST_F() local
[all …]
/external/apache-harmony/luni/src/test/api/common/org/apache/harmony/luni/tests/java/net/
DAuthenticatorTest.java77 MockAuthenticator mock = new MockAuthenticator(); in test_requestPasswordAuthentication_InetAddress_int_String_String_String() local
79 Authenticator.setDefault(mock); in test_requestPasswordAuthentication_InetAddress_int_String_String_String()
81 assertEquals(mock.getRequestorType(), RequestorType.SERVER); in test_requestPasswordAuthentication_InetAddress_int_String_String_String()
89 MockAuthenticator mock = new MockAuthenticator(); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String() local
91 Authenticator.setDefault(mock); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String()
93 assertEquals(mock.getRequestorType(), RequestorType.SERVER); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String()
103 MockAuthenticator mock = new MockAuthenticator(); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String_URL_Authenticator_RequestorType() local
108 assertNull(mock.getRequestingURL()); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String_URL_Authenticator_RequestorType()
109 assertNull(mock.getRequestorType()); in test_requestPasswordAuthentication_String_InetAddress_int_String_String_String_URL_Authenticator_RequestorType()
117 MockAuthenticator mock = new MockAuthenticator(); in test_getRequestingURL() local
[all …]
/external/easymock/src/org/easymock/internal/
DInvocation.java33 private final Object mock; field in Invocation
42 public Invocation(Object mock, Method method, Object[] args) { in Invocation() argument
43 this.mock = mock; in Invocation()
77 return mock; in getMock()
95 return this.mock.equals(other.mock) && this.method.equals(other.method) in equals()
136 return this.mock.equals(actual.mock) in matches()
147 String mockName = mock.toString(); in getMockAndMethodName()
149 if (toStringIsDefined(mock) && isJavaIdentifier(mockName)) { in getMockAndMethodName()
/external/chromium/net/proxy/
Dmulti_threaded_proxy_resolver_unittest.cc237 scoped_ptr<MockProxyResolver> mock(new MockProxyResolver); in TEST() local
239 new ForwardingProxyResolverFactory(mock.get()), kNumThreads); in TEST()
254 mock->last_script_data()->utf16()); in TEST()
316 EXPECT_EQ(0, mock->purge_count()); in TEST()
325 EXPECT_EQ(1, mock->purge_count()); in TEST()
333 scoped_ptr<BlockableProxyResolver> mock(new BlockableProxyResolver); in TEST() local
335 new ForwardingProxyResolverFactory(mock.get()), kNumThreads); in TEST()
346 mock->Block(); in TEST()
375 mock->WaitUntilBlocked(); in TEST()
376 mock->Unblock(); in TEST()
[all …]
/external/easymock/src/org/easymock/
DEasyMock.java1546 for (Object mock : mocks) { in replay()
1547 getControl(mock).replay(); in replay()
1559 for (Object mock : mocks) { in reset()
1560 getControl(mock).reset(); in reset()
1573 for (Object mock : mocks) { in resetToNice()
1574 getControl(mock).resetToNice(); in resetToNice()
1587 for (Object mock : mocks) { in resetToDefault()
1588 getControl(mock).resetToDefault(); in resetToDefault()
1601 for (Object mock : mocks) { in resetToStrict()
1602 getControl(mock).resetToStrict(); in resetToStrict()
[all …]
/external/chromium/chrome/common/
Dchild_process_logging_mac_unittest.mm17 // Class to mock breakpad's setkeyvalue/clearkeyvalue functions needed for
115 MockBreakpadKeyValueStore mock;
117 EXPECT_EQ(mock.CountDictionaryEntries(), 0);
121 EXPECT_TRUE(mock.VerifyDictionaryContents(short_url));
122 EXPECT_EQ(mock.CountDictionaryEntries(), 1);
124 EXPECT_EQ(mock.CountDictionaryEntries(), 0);
128 EXPECT_TRUE(mock.VerifyDictionaryContents(long_url));
130 EXPECT_TRUE(mock.VerifyDictionaryContents(short_url));
132 EXPECT_EQ(mock.CountDictionaryEntries(), 0);
137 EXPECT_TRUE(mock.VerifyDictionaryContents(
[all …]
/external/webkit/LayoutTests/fast/url/
Dfile-expected.txt6 FAIL canonicalize('file:c:\\foo\\bar.html') should be file:///C:/foo/bar.html. Was file:///tmp/mock
7 …|////foo\\bar.html') should be file:///C:////foo/bar.html. Was file:///tmp/mock/c|////foo/bar.html.
8 FAIL canonicalize('file:') should be file:///. Was file:///tmp/mock/path.
9 FAIL canonicalize('file:UNChost/path') should be file://unchost/path. Was file:///tmp/mock/UNChost/…
11 FAIL canonicalize('C|/foo/bar') should be file:///C:/foo/bar. Was file:///tmp/mock/C|/foo/bar.
17 FAIL canonicalize('file:c:foo/bar.html') should be file:///C:/foo/bar.html. Was file:///tmp/mock/c:…
21 FAIL canonicalize('file:filer/home\\me') should be file://filer/home/me. Was file:///tmp/mock/filer…
25 FAIL canonicalize('file:c:\\foo\\bar.html') should be file:///c:/foo/bar.html. Was file:///tmp/mock
26 …le:c|//foo\\bar.html') should be file:///c%7C//foo/bar.html. Was file:///tmp/mock/c|//foo/bar.html.
/external/chromium/chrome/browser/automation/
Dautomation_provider_unittest.cc33 mock(new MockChromeFrameAutomationProvider(NULL)); in TEST_F() local
35 EXPECT_CALL(*mock, OnUnhandledMessage(testing::Property(&IPC::Message::type, in TEST_F()
37 mock->OnMessageReceived(bad_msg); in TEST_F()
/external/apache-harmony/luni/src/test/api/common/org/apache/harmony/luni/tests/java/lang/
DEnumTest.java232 MockEnum mock = new MockEnum(); in testSerializationSelf() local
233 MockEnum test = (MockEnum) SerializationTest.copySerializable(mock); in testSerializationSelf()
234 assertEquals(mock.i, test.i); in testSerializationSelf()
235 assertEquals(mock.str, test.str); in testSerializationSelf()
236 assertEquals(mock.samEnum, test.samEnum); in testSerializationSelf()
/external/apache-harmony/beans/src/test/support/java/org/apache/harmony/beans/tests/support/mock/
DMockPropertyChangeListener2.java18 package org.apache.harmony.beans.tests.support.mock;
28 org.apache.harmony.beans.tests.support.mock.MockPropertyChangeEvent e); in mockPropertyChange()
/external/android-mock/
DHOWTO.txt1 This is a copy from the android mock project, http://code.google.com/p/android-mock/. To regenerate…
Dbuild.properties2 framework.mock-bin=bin
3 framework.mock-jar=android_framework_mocks.jar
DAndroid.mk23 LOCAL_MODULE := android-mock-runtimelib
37 LOCAL_MODULE := android-mock-generatorlib
/external/apache-harmony/nio/src/test/java/common/org/apache/harmony/nio/tests/java/nio/channels/spi/
DAbstractSelectableChannelTest.java277 MockSelectableChannel mock = new MockSelectableChannel(SelectorProvider in test_configureBlocking_Z() local
281 mock.configureBlocking(true); in test_configureBlocking_Z()
282 assertFalse(mock.implConfigureBlockingCalled); in test_configureBlocking_Z()
283 mock.configureBlocking(false); in test_configureBlocking_Z()
284 assertTrue(mock.implConfigureBlockingCalled); in test_configureBlocking_Z()
/external/chromium/chrome/browser/chromeos/login/
Dmock_owner_key_utils.h48 explicit MockInjector(MockKeyUtils* mock) : transient_(mock) { in MockInjector() argument
/external/chromium/testing/gmock/include/gmock/
Dgmock-generated-nice-strict.h.pump39 // Given a mock class MockFoo that is created using Google Mock,
41 // uninteresting calls (i.e. calls to mock methods that have no
47 // write NiceMock<MockFoo>(5, "a") to construct a nice mock where
52 // StrictMock<MockFoo> only works for mock methods defined using the
54 // mock method is defined in a base class of MockFoo, the "nice" or
58 // Another known limitation is that the constructors of the base mock
Dgmock-generated-function-mockers.h.pump37 // Google Mock - a framework for writing C++ mock classes.
202 // A MockFunction<F> class has one mock method whose type is F. It is
212 // mock.Bar("a"), but Foo(2) doesn't invoke anything, you can write:
215 // MyMock mock;
220 // EXPECT_CALL(mock, Bar("a"));
223 // EXPECT_CALL(mock, Bar("a"));
/external/android-mock/src/com/google/android/testing/mocking/
DAndroidMock.java2564 public static void checkOrder(Object mock, boolean orderCheckingOn) { in checkOrder() argument
2565 if (mock instanceof MockObject) { in checkOrder()
2566 EasyMock.checkOrder(((MockObject) mock).getDelegate___AndroidMock(), orderCheckingOn); in checkOrder()
2568 EasyMock.checkOrder(mock, orderCheckingOn); in checkOrder()
2620 public static void makeThreadSafe(Object mock, boolean threadSafe) { in makeThreadSafe() argument
2621 if (mock instanceof MockObject) { in makeThreadSafe()
2622 EasyMock.makeThreadSafe(((MockObject) mock).getDelegate___AndroidMock(), threadSafe); in makeThreadSafe()
2624 EasyMock.makeThreadSafe(mock, threadSafe); in makeThreadSafe()

12345