OpenGrok
Home
Sort by relevance
Sort by last modified time
Full Search
Definition
Symbol
File Path
History
|
|
Help
Searched
refs:shadowOf
(Results
1 - 25
of
192
) sorted by null
1
2
3
4
5
6
7
8
/external/robolectric/src/test/java/com/xtremelabs/robolectric/shadows/
NotificationManagerTest.java
12
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
29
assertEquals(1,
shadowOf
(notificationManager).size());
30
assertEquals(notification1,
shadowOf
(notificationManager).getNotification(1));
33
assertEquals(2,
shadowOf
(notificationManager).size());
34
assertEquals(notification2,
shadowOf
(notificationManager).getNotification(31));
42
assertEquals(1,
shadowOf
(notificationManager).size());
43
assertEquals(notification2,
shadowOf
(notificationManager).getNotification(1));
49
assertEquals(1,
shadowOf
(notificationManager).size());
50
assertEquals(notification1,
shadowOf
(notificationManager).getNotification("a tag"));
56
assertEquals(1,
shadowOf
(notificationManager).size())
[
all
...]
AlphaAnimationTest.java
8
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
15
assertEquals(99.0f,
shadowOf
(new AlphaAnimation(99, 88)).getFromAlpha());
16
assertEquals(66.7f,
shadowOf
(new AlphaAnimation(66.7f, 88)).getFromAlpha());
21
assertEquals(88.0f,
shadowOf
(new AlphaAnimation(99, 88)).getToAlpha());
22
assertEquals(98f,
shadowOf
(new AlphaAnimation(66.7f, 98)).getToAlpha());
JsResultTest.java
9
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
20
assertFalse(
shadowOf
(jsResult).wasCancelled());
23
assertTrue(
shadowOf
(jsResult).wasCancelled());
GeocoderTest.java
13
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
31
String lastLocationName =
shadowOf
(geocoder).getLastLocationName();
38
shadowOf
(geocoder).setSimulatedHasLatLong(true, true);
42
shadowOf
(geocoder).setSimulatedHasLatLong(false, false);
50
shadowOf
(geocoder).setReturnNoResults(true);
58
assertFalse(
shadowOf
(geocoder).didResolution());
59
shadowOf
(geocoder).setReturnNoResults(true);
61
assertTrue(
shadowOf
(geocoder).didResolution());
LooperTest.java
11
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
73
assertTrue(
shadowOf
(looper).hasQuit());
74
assertFalse(
shadowOf
(looper).post(new Runnable() {
78
assertFalse(
shadowOf
(looper).postAtFrontOfQueue(new Runnable() {
83
assertFalse(
shadowOf
(looper).getScheduler().areAnyRunnable());
91
shadowOf
(looper).pause();
92
shadowOf
(looper).post(new Runnable() {
98
assertTrue(
shadowOf
(looper).hasQuit());
99
assertFalse(
shadowOf
(looper).getScheduler().areAnyRunnable());
104
assertTrue(
shadowOf
(Looper.getMainLooper()).getThread() == Thread.currentThread())
[
all
...]
BitmapTest.java
15
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
25
shadowOf
(originalBitmap).appendDescription("Original bitmap");
27
assertEquals("Original bitmap scaled to 100 x 200",
shadowOf
(scaledBitmap).getDescription());
47
shadowOf
(originalBitmap).appendDescription("Original bitmap");
49
assertEquals("Original bitmap created from Bitmap object",
shadowOf
(newBitmap).getDescription());
70
shadowOf
(bitmapA1).setWidth(100);
71
shadowOf
(bitmapA1).setHeight(100);
74
shadowOf
(bitmapA2).setWidth(101);
75
shadowOf
(bitmapA2).setHeight(101);
83
shadowOf
(bitmap1).appendDescription("Bitmap One")
[
all
...]
CanvasTest.java
10
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
33
"Bitmap for file:/an/image.jpg at (100,200)",
shadowOf
(canvas).getDescription());
36
"Bitmap for file:/an/image.jpg at (100,200)",
shadowOf
(targetBitmap).getDescription());
46
"Bitmap for file:/an/image.jpg transformed by matrix",
shadowOf
(canvas).getDescription());
49
"Bitmap for file:/an/image.jpg transformed by matrix",
shadowOf
(targetBitmap).getDescription());
70
shadowOf
(canvas).getDescription());
83
ShadowCanvas shadow =
shadowOf
(canvas);
103
assertEquals("Path " +
shadowOf
(path1).getPoints().toString() + "\n"
104
+ "Path " +
shadowOf
(path2).getPoints().toString(),
shadowOf
(canvas).getDescription())
[
all
...]
KeyguardManagerTest.java
10
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
24
ShadowKeyguardManager shadowMgr =
shadowOf
(mgr);
34
assertTrue(
shadowOf
(lock).isEnabled());
37
assertFalse(
shadowOf
(lock).isEnabled());
40
assertTrue(
shadowOf
(lock).isEnabled());
StateListDrawableTest.java
11
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
27
ShadowStateListDrawable shadow =
shadowOf
(stateListDrawable);
30
assertThat(((ShadowBitmapDrawable)
shadowOf
(drawableForState)).getPath(), is("/foo"));
40
ShadowStateListDrawable shadow =
shadowOf
(stateListDrawable);
43
assertThat(((ShadowBitmapDrawable)
shadowOf
(drawableForState)).getPath(), is("/foo"));
ActivityGroupTest.java
9
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
20
shadowOf
(activityGroup).setCurrentActivity(activity);
BaseAdapterTest.java
10
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
20
assertTrue(
shadowOf
(adapter).wasNotifyDataSetChangedCalled());
27
shadowOf
(adapter).clearWasDataSetChangedCalledFlag();
28
assertFalse(
shadowOf
(adapter).wasNotifyDataSetChangedCalled());
PaintTest.java
11
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
22
ShadowPaint shadowPaint =
shadowOf
(paint);
31
ShadowPaint shadowPaint =
shadowOf
(paint);
40
ShadowPaint shadowPaint =
shadowOf
(paint);
TelephonyManagerTest.java
13
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
30
shadowManager =
shadowOf
(manager);
47
shadowOf
(telephonyManager).setDeviceId(testId);
54
ShadowTelephonyManager shadowTelephonyManager =
shadowOf
(telephonyManager);
62
ShadowTelephonyManager shadowTelephonyManager =
shadowOf
(telephonyManager);
70
ShadowTelephonyManager shadowTelephonyManager =
shadowOf
(telephonyManager);
84
ShadowTelephonyManager shadowTelephonyManager =
shadowOf
(telephonyManager);
TabSpecTest.java
17
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
37
assertThat(
shadowOf
(spec).getIndicatorAsView(), is(view));
46
assertThat(
shadowOf
(spec).getContentAsIntent(), is(intent));
56
assertThat(
shadowOf
(spec).getIndicatorLabel(), is("labelText"));
57
assertThat(
shadowOf
(spec).getText(), is("labelText"));
64
assertThat(
shadowOf
(spec).getIndicatorLabel(), is("labelText"));
65
assertThat(
shadowOf
(spec).getText(), is("labelText"));
66
assertThat(
shadowOf
(spec).getIndicatorIcon(), is(icon1));
80
ShadowTabSpec shadowFoo =
shadowOf
(foo);
92
ShadowTabSpec shadowFoo =
shadowOf
(foo)
[
all
...]
ViewTreeObserverTest.java
12
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
35
shadowOf
(viewTreeObserver).fireOnGlobalLayoutListeners();
42
shadowOf
(viewTreeObserver).fireOnGlobalLayoutListeners();
50
shadowOf
(viewTreeObserver).fireOnGlobalLayoutListeners();
61
List<ViewTreeObserver.OnGlobalLayoutListener> listeners =
shadowOf
(viewTreeObserver).getOnGlobalLayoutListeners();
LayerDrawableTest.java
13
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
51
assertSame("drawables", drawables,
shadowOf
(layerDrawable).drawables);
69
assertEquals(
shadowOf
(drawable4000).getLoadedFromResourceId(),
70
shadowOf
(layerDrawable.getDrawable(index)).getLoadedFromResourceId());
82
assertEquals(
shadowOf
(drawable4000).getLoadedFromResourceId(),
83
shadowOf
(layerDrawable.getDrawable(index)).getLoadedFromResourceId());
/external/robolectric/src/main/java/com/xtremelabs/robolectric/
Robolectric.java
392
public static ShadowAbsListView
shadowOf
(AbsListView instance) {
396
public static ShadowAbsSeekBar
shadowOf
(AbsSeekBar instance) {
400
public static ShadowAccountManager
shadowOf
(AccountManager instance) {
404
public static ShadowActivity
shadowOf
(Activity instance) {
408
public static ShadowActivityGroup
shadowOf
(ActivityGroup instance) {
412
public static ShadowActivityManager
shadowOf
(ActivityManager instance) {
416
public static ShadowAdapterView
shadowOf
(AdapterView instance) {
420
public static ShadowAddress
shadowOf
(Address instance) {
424
public static ShadowAlarmManager
shadowOf
(AlarmManager instance) {
428
public static ShadowAlertDialog
shadowOf
(AlertDialog instance)
[
all
...]
RobolectricShadowOfLevel9.java
13
public static ShadowNdefMessage
shadowOf
(NdefMessage instance) {
17
public static ShadowNdefRecord
shadowOf
(NdefRecord instance) {
21
public static ShadowNfcAdapter
shadowOf
(NfcAdapter instance) {
RobolectricForMaps.java
13
public static ShadowGeoPoint
shadowOf
(GeoPoint instance) {
17
public static ShadowMapView
shadowOf
(MapView instance) {
21
public static ShadowMapController
shadowOf
(MapController instance) {
25
public static ShadowItemizedOverlay
shadowOf
(ItemizedOverlay instance) {
/external/robolectric/src/main/java/com/xtremelabs/robolectric/shadows/
ShadowMatrix.java
7
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
33
transX =
shadowOf
(src).transX;
34
scaleX =
shadowOf
(src).scaleX;
36
transY =
shadowOf
(src).transY;
37
scaleY =
shadowOf
(src).scaleY;
ShadowMenuInflater.java
9
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
26
shadowOf
(context.getApplicationContext()).getResourceLoader().inflateMenu(context, resource, root);
ShadowLooper.java
9
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
46
final ShadowLooper looper =
shadowOf
(myLooper());
47
if (looper !=
shadowOf
(getMainLooper())) {
66
if (this ==
shadowOf
(getMainLooper())) throw new RuntimeException("Main thread not allowed to quit");
84
shadowOf
(looper).pause();
88
shadowOf
(looper).unPause();
100
shadowOf
(Looper.getMainLooper()).idle(interval);
ShadowBitmap.java
12
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
41
ShadowBitmap shadowBitmap =
shadowOf
(scaledBitmap);
51
ShadowBitmap shadowBitmap =
shadowOf
(bitmap);
59
ShadowBitmap shadowBitmap =
shadowOf
(scaledBitmap);
60
shadowBitmap.appendDescription(
shadowOf
(src).getDescription());
82
ShadowBitmap shadowBitmap =
shadowOf
(realBitmap);
120
shadowOf
(bitmap).appendDescription(name);
158
ShadowBitmap that =
shadowOf
((Bitmap) o);
/external/robolectric/src/main/java/com/xtremelabs/robolectric/internal/
AppSingletonizer.java
8
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
19
ShadowApplication shadowApplication = (ShadowApplication)
shadowOf
(applicationContext);
/external/robolectric/src/main/java/com/xtremelabs/robolectric/matchers/
HasResourceMatcher.java
9
import static com.xtremelabs.robolectric.Robolectric.
shadowOf
;
25
actualResourceId =
shadowOf
(actual).getResourceId();
Completed in 725 milliseconds
1
2
3
4
5
6
7
8