HomeSort by relevance Sort by last modified time
    Searched defs:mock (Results 51 - 75 of 114) sorted by null

1 23 4 5

  /external/chromium/testing/gmock/test/
gmock_link_test.h 32 // Google Mock - a framework for writing C++ mock classes.
35 // a. A header file defining a mock class can be included in multiple
104 // This test requires identical definitions of Interface and Mock to be
109 // definitions of Interface and Mock tests MUST be kept in the SAME
205 class Mock: public Interface {
207 Mock() {}
220 GTEST_DISALLOW_COPY_AND_ASSIGN_(Mock);
243 Mock mock; local
251 Mock mock; local
260 Mock mock; local
268 Mock mock; local
277 Mock mock; local
286 Mock mock; local
295 Mock mock; local
308 Mock mock; local
320 Mock mock; local
332 Mock mock; local
345 Mock mock; local
354 Mock mock; local
363 Mock mock; local
372 Mock mock; local
380 Mock mock; local
390 Mock mock; local
400 Mock mock; local
409 Mock mock; local
432 Mock mock; local
444 Mock mock; local
462 Mock mock; local
472 Mock mock; local
479 Mock mock; local
486 Mock mock; local
496 Mock mock; local
507 Mock mock; local
514 Mock mock; local
521 Mock mock; local
529 Mock mock; local
538 Mock mock; local
550 Mock mock; local
557 Mock mock; local
564 Mock mock; local
573 Mock mock; local
582 Mock mock; local
589 Mock mock; local
597 Mock mock; local
    [all...]
  /external/chromium-trace/trace-viewer/third_party/pywebsocket/src/test/
test_dispatch.py 43 from test import mock namespace
149 request = mock.MockRequest()
165 request = mock.MockRequest()
173 request = mock.MockRequest(connection=mock.MockConn('\xff\x00'))
181 request = mock.MockRequest(connection=mock.MockConn('\xff\x00'))
189 request = mock.MockRequest(connection=mock.MockConn('\xff\x00'))
197 request = mock.MockRequest(connection=mock.MockConn('\xff\x00')
    [all...]
test_handshake_draft75.py 41 from test import mock namespace
369 conn = mock.MockConn('')
371 return mock.MockRequest(
401 mock.MockDispatcher())
415 mock.MockDispatcher())
424 mock.MockDispatcher())
434 mock.MockDispatcher())
443 mock.MockDispatcher())
452 mock.MockDispatcher())
462 mock.MockDispatcher()
    [all...]
test_handshake_hybi00.py 42 from test import mock namespace
320 conn = mock.MockConn(data)
322 return mock.MockRequest(
352 mock.MockDispatcher())
364 mock.MockDispatcher())
374 mock.MockDispatcher())
383 mock.MockDispatcher())
393 mock.MockDispatcher())
402 mock.MockDispatcher())
411 mock.MockDispatcher()
    [all...]
test_handshake_hybi08.py 45 import mock namespace
71 conn = mock.MockConn('')
72 return mock.MockRequest(
80 handshaker = Handshaker(request, mock.MockDispatcher())
148 dispatcher = mock.MockDispatcher()
359 handshaker = Handshaker(request, mock.MockDispatcher())
test_handshake_hybi.py 45 import mock namespace
71 conn = mock.MockConn('')
72 return mock.MockRequest(
80 handshaker = Handshaker(request, mock.MockDispatcher())
148 dispatcher = mock.MockDispatcher()
420 handshaker = Handshaker(request, mock.MockDispatcher())
test_mux.py 52 import mock namespace
64 class _MockMuxConnection(mock.MockBlockingConn):
65 """Mock class of mod_python connection for mux."""
68 mock.MockBlockingConn.__init__(self)
165 """Mock class of dispatch.Dispatcher for mux."""
217 request = mock.MockRequest(uri='/echo',
  /external/chromium_org/chrome/browser/download/
download_query_unittest.cc 57 EXPECT_CALL(mock(mocks_.size() - 1), GetId()).WillRepeatedly(Return(
62 content::MockDownloadItem& mock(int index) { return *mocks_[index]; } function in class:DownloadQueryTest
75 // Filter tests generally contain 2 items. mock(0) matches the filter, mock(1)
188 EXPECT_CALL(mock(0), GetBrowserContext()).WillRepeatedly(Return(
190 EXPECT_CALL(mock(1), GetBrowserContext()).WillRepeatedly(Return(
193 EXPECT_CALL(mock(0), GetTargetFilePath()).WillRepeatedly(ReturnRef(
196 EXPECT_CALL(mock(1), GetTargetFilePath()).WillRepeatedly(ReturnRef(
199 EXPECT_CALL(mock(0), GetOriginalUrl()).WillRepeatedly(ReturnRef(fail_url));
200 EXPECT_CALL(mock(1), GetOriginalUrl()).WillRepeatedly(ReturnRef(fail_url))
    [all...]
  /external/chromium_org/native_client_sdk/src/tools/tests/
create_nmf_test.py 18 # For the mock library
24 import mock namespace
89 with mock.patch.dict('os.environ', clear=True):
94 with mock.patch.dict('os.environ', {'NACL_SDK_ROOT': '/dummy/path'}):
100 with mock.patch.dict('os.environ', {'NACL_SDK_ROOT': '/dummy/path'}):
getos_test.py 17 # For the mock library
19 import mock namespace
39 self.patch1 = mock.patch.dict('os.environ',
42 self.patch2 = mock.patch.object(oshelpers, 'FindExeInPath',
52 with mock.patch.dict('os.environ', {'NACL_SDK_ROOT': 'dummy'}):
72 with mock.patch.dict('os.environ', {'CHROME_PATH': '/dummy/file'}):
88 with mock.patch.dict('os.environ', {'CHROME_PATH': mock_location}):
89 with mock.patch('os.path.exists') as mock_exists:
100 with mock.patch('os.path.exists') as mock_exists:
110 with mock.patch('os.path.exists') as mock_exists
    [all...]
  /external/mockito/src/org/mockito/
Mockito.java 37 * <a href="#7">7. Making sure interaction(s) never happened on mock </a><br/>
39 * <a href="#9">9. Shorthand for mocks creation - <code>&#064;Mock</code> annotation </a><br/>
62 * Following examples mock a List, because everyone knows its interface (methods
64 * You probably wouldn't mock List class 'in real'.
75 * //mock creation
76 * List mockedList = mock(List.class);
78 * //using mock object
88 * Once created, mock will remember all interactions. Then you can selectively
97 * //You can mock concrete classes, not only interfaces
98 * LinkedList mockedList = mock(LinkedList.class);
1119 public static <T> T mock(Class<T> classToMock) { method in class:Mockito
1138 public static <T> T mock(Class<T> classToMock, String name) { method in class:Mockito
1192 public static <T> T mock(Class<T> classToMock, ReturnValues returnValues) { method in class:Mockito
1215 public static <T> T mock(Class<T> classToMock, Answer defaultAnswer) { method in class:Mockito
1242 public static <T> T mock(Class<T> classToMock, MockSettings mockSettings) { method in class:Mockito
    [all...]
  /external/mockito/src/org/mockito/internal/invocation/
InvocationImpl.java 19 * Method call on a mock object.
31 private final Object mock; field in class:InvocationImpl
43 public InvocationImpl(Object mock, MockitoMethod mockitoMethod, Object[] args, int sequenceNumber, RealMethod realMethod) {
45 this.mock = mock;
54 return mock;
80 return this.mock.equals(other.mock) && this.method.equals(other.method) && this.equalArguments(other.arguments);
108 return realMethod.invoke(mock, rawArguments);
  /frameworks/base/core/tests/coretests/src/android/widget/focus/
RequestFocusTest.java 20 import static com.google.testing.littlemock.LittleMock.mock;
133 CombinedListeners mock = mock(CombinedListeners.class); local
134 clearingFocusButton.setOnFocusChangeListener(mock);
135 gainingFocusButton.setOnFocusChangeListener(mock);
136 clearingFocusButton.getViewTreeObserver().addOnGlobalFocusChangeListener(mock);
142 InOrder inOrder = inOrder(mock);
143 inOrder.verify(mock).onFocusChange(clearingFocusButton, false);
144 inOrder.verify(mock).onGlobalFocusChanged(clearingFocusButton, gainingFocusButton);
145 inOrder.verify(mock).onFocusChange(gainingFocusButton, true)
176 CombinedListeners mock = mock(CombinedListeners.class); local
    [all...]
  /frameworks/base/test-runner/src/android/test/mock/
MockResources.java 17 package android.test.mock;
35 * A mock {@link android.content.res.Resources} class. All methods are non-functional and throw
52 throw new UnsupportedOperationException("mock object, not implemented");
57 throw new UnsupportedOperationException("mock object, not implemented");
62 throw new UnsupportedOperationException("mock object, not implemented");
67 throw new UnsupportedOperationException("mock object, not implemented");
73 throw new UnsupportedOperationException("mock object, not implemented");
78 throw new UnsupportedOperationException("mock object, not implemented");
83 throw new UnsupportedOperationException("mock object, not implemented");
88 throw new UnsupportedOperationException("mock object, not implemented")
    [all...]
MockCursor.java 17 package android.test.mock;
31 * A mock {@link android.database.Cursor} class that isolates the test code from real
41 throw new UnsupportedOperationException("unimplemented mock method");
45 throw new UnsupportedOperationException("unimplemented mock method");
49 throw new UnsupportedOperationException("unimplemented mock method");
53 throw new UnsupportedOperationException("unimplemented mock method");
57 throw new UnsupportedOperationException("unimplemented mock method");
61 throw new UnsupportedOperationException("unimplemented mock method");
65 throw new UnsupportedOperationException("unimplemented mock method");
69 throw new UnsupportedOperationException("unimplemented mock method")
    [all...]
  /external/mockito/src/org/mockito/internal/
MockitoCore.java 29 import org.mockito.mock.MockCreationSettings;
47 public <T> T mock(Class<T> typeToMock, MockSettings settings) { method in class:MockitoCore
55 T mock = mockUtil.createMock(creationSettings); local
56 mockingProgress.mockingStarted(mock, typeToMock);
57 return mock;
79 public <T> T verify(T mock, VerificationMode mode) {
80 if (mock == null) {
82 } else if (!mockUtil.isMock(mock)) {
83 reporter.notAMockPassedToVerify(mock.getClass());
85 mockingProgress.verificationStarted(new MockAwareVerificationMode(mock, mode));
    [all...]
  /cts/tests/tests/database/src/android/database/cts/
AbstractCursorTest.java 152 MockDataSetObserver mock = new MockDataSetObserver(); local
153 mDatabaseCursor.registerDataSetObserver(mock);
154 assertFalse(mock.hadCalledOnChanged());
156 assertTrue(mock.hadCalledOnChanged());
160 MockContentObserver mock = new MockContentObserver(); local
161 mTestAbstractCursor.registerContentObserver(mock);
162 assertFalse(mock.hadCalledOnChange());
165 if ( !mock.hadCalledOnChange() ) {
169 assertTrue(mock.hadCalledOnChange());
335 MockDataSetObserver mock = new MockDataSetObserver() local
    [all...]
  /external/chromium/chrome/browser/policy/
device_management_service_unittest.cc 105 DeviceRegisterResponseDelegateMock mock; local
106 EXPECT_CALL(mock, OnError(GetParam().expected_error_));
108 backend_->ProcessRegisterRequest(kAuthToken, kDeviceId, request, &mock);
121 DeviceUnregisterResponseDelegateMock mock; local
122 EXPECT_CALL(mock, OnError(GetParam().expected_error_));
124 backend_->ProcessUnregisterRequest(kDMToken, kDeviceId, request, &mock);
137 DevicePolicyResponseDelegateMock mock; local
138 EXPECT_CALL(mock, OnError(GetParam().expected_error_));
144 backend_->ProcessPolicyRequest(kDMToken, kDeviceId, request, &mock);
289 DeviceRegisterResponseDelegateMock mock; local
324 DeviceUnregisterResponseDelegateMock mock; local
366 DeviceRegisterResponseDelegateMock mock; local
378 DeviceUnregisterResponseDelegateMock mock; local
390 DevicePolicyResponseDelegateMock mock; local
411 DeviceRegisterResponseDelegateMock mock; local
441 DevicePolicyResponseDelegateMock mock; local
460 DeviceRegisterResponseDelegateMock mock; local
    [all...]
  /external/chromium_org/chrome_frame/test/
urlmon_moniker_unittest.cc 99 CComObjectStackEx<MockBindStatusCallbackImpl> mock; local
110 EXPECT_CALL(mock, OnDataAvailable(flags, size,
118 EXPECT_HRESULT_SUCCEEDED(CacheStream::BSCBFeedData(&mock, data, size, cf,
170 CComObjectStackEx<MockBindStatusCallbackImpl> mock; local
183 EXPECT_CALL(mock, OnDataAvailable(flags, data_size,
191 EXPECT_HRESULT_SUCCEEDED(sniffer.DrainCache(&mock, flags, cf));
213 CComObjectStackEx<MockBindStatusCallbackImpl> mock; local
229 EXPECT_CALL(mock, OnDataAvailable(flags, data_size,
238 EXPECT_HRESULT_SUCCEEDED(sniffer.DrainCache(&mock, flags, cf));
util_unittests.cc 192 // Mock for the IInternetSecurityManager interface
223 // This class provides a partial mock for the NavigationConstraints
231 // Mock NavigationConstraints
245 ACTION_P3(HandleZone, mock, url_prefix, zone) {
252 MockNavigationConstraintsZoneOverride mock; local
271 EXPECT_CALL(mock, IsZoneAllowed(UrlPathStartsWith(zone.url_prefix)))
311 mock.set_is_privileged(test.is_privileged);
312 bool actual = CanNavigate(GURL(test.url), &mock);
318 MockNavigationConstraints mock; local
320 EXPECT_CALL(mock, IsZoneAllowed(testing::_)
357 MockNavigationConstraints mock; local
396 MockNavigationConstraints mock; local
    [all...]
  /external/chromium_org/native_client_sdk/src/tests/nacl_io_test/
kernel_wrap_test.cc 112 EXPECT_CALL(mock, open(_, _))
117 EXPECT_CALL(mock, mount(_, _, _, _, _))
121 ki_init(&mock);
126 KernelProxyMock mock; member in class:__anon8836::KernelWrapTest
132 EXPECT_CALL(mock, access(kDummyConstChar, kDummyInt)) .WillOnce(Return(-1));
135 EXPECT_CALL(mock, access(kDummyConstChar, kDummyInt)) .WillOnce(Return(0));
140 EXPECT_CALL(mock, chdir(kDummyConstChar)).WillOnce(Return(-1));
143 EXPECT_CALL(mock, chdir(kDummyConstChar)).WillOnce(Return(0));
148 EXPECT_CALL(mock, chmod(kDummyConstChar, kDummyInt))
154 EXPECT_CALL(mock, chown(kDummyConstChar, kDummyUid, kDummyGid)
    [all...]
  /external/chromium_org/ui/message_center/views/
message_center_view_unittest.cc 29 /* Instrumented/Mock NotificationView subclass ********************************/
159 MockNotificationView* mock; local
160 mock = new MockNotificationView(this, notification, this);
161 message_center_view_->notification_views_[notification.id()] = mock;
162 message_center_view_->SetNotificationViewForTest(mock);
  /external/easymock/src/org/easymock/
MockControl.java 26 * mock object. For more information, see the EasyMock documentation.
28 * @param <T> type of the mock controlled
31 * used to create and control mock objects.
38 private final T mock; field in class:MockControl
44 this.mock = ctrl.createMock(toMock);
48 * Creates a mock control object for the specified interface. The
49 * <code>MockControl</code> and its associated mock object will not check
50 * the order of expected method calls. An unexpected method call on the mock
53 * @param <T> type of the mock controlled
55 * the class of the interface to mock.
    [all...]
  /external/easymock/src/org/easymock/internal/
Invocation.java 33 private final Object mock; field in class:Invocation
42 public Invocation(Object mock, Method method, Object[] args) {
43 this.mock = mock;
77 return mock;
95 return this.mock.equals(other.mock) && this.method.equals(other.method)
136 return this.mock.equals(actual.mock)
147 String mockName = mock.toString();
    [all...]
  /frameworks/base/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/unit/
CameraUtilsBinderDecoratorTest.java 72 ICameraBinderStereotype mock = mock(ICameraBinderStereotype.class); local
74 when(mock.doNothing()).thenReturn(SOME_ARBITRARY_DOUBLE);
75 when(mock.doSomethingPositive()).thenReturn(SOME_ARBITRARY_POSITIVE_INT);
76 when(mock.doSomethingNoError()).thenReturn(NO_ERROR);
77 when(mock.doSomethingPermissionDenied()).thenReturn(PERMISSION_DENIED);
78 when(mock.doSomethingAlreadyExists()).thenReturn(ALREADY_EXISTS);
79 when(mock.doSomethingBadValue()).thenReturn(BAD_VALUE);
80 when(mock.doSomethingDeadObject()).thenReturn(DEAD_OBJECT);
81 when(mock.doSomethingBadPolicy()).thenReturn(EACCES)
    [all...]

Completed in 185 milliseconds

1 23 4 5