/cts/tests/tests/content/src/android/content/res/cts/ |
D | ResourcesTest.java | 55 private Resources mResources; field in ResourcesTest 61 mResources = getContext().getResources(); in setUp() 78 mResources.getString(-1, "%s"); in testGetString() 84 final String strGo = mResources.getString(R.string.go, "%1$s%%", 12); in testGetString() 89 final XmlPullParser parser = mResources.getXml(R.xml.test_color); in testObtainAttributes() 92 final TypedArray testTypedArray = mResources.obtainAttributes(set, R.styleable.Style1); in testObtainAttributes() 97 assertEquals(mResources, testTypedArray.getResources()); in testObtainAttributes() 103 mResources.obtainTypedArray(-1); in testObtainTypedArray() 109 final TypedArray ta = mResources.obtainTypedArray(R.array.string); in testObtainTypedArray() 114 assertEquals(mResources, ta.getResources()); in testObtainTypedArray() [all …]
|
D | PrimitiveTest.java | 27 private Resources mResources; field in PrimitiveTest 32 mResources = mContext.getResources(); in setUp() 117 mResources.getString(R.string.formattedStringNone), in testFormattedString() 120 mResources.getString(R.string.formattedStringOne), in testFormattedString() 123 mResources.getString(R.string.formattedStringTwo), in testFormattedString() 127 mResources.getString(R.string.formattedStringNone), in testFormattedString() 130 mResources.getString(R.string.formattedStringOne, 42), in testFormattedString() 133 mResources.getString(R.string.formattedStringTwo, "unused", "hi", 43), in testFormattedString()
|
D | ArrayTest.java | 26 private Resources mResources; field in ArrayTest 31 mResources = mContext.getResources(); in setUp() 41 final String[] res = mResources.getStringArray(resid); in checkStringArray() 49 final CharSequence[] res = mResources.getTextArray(resid); in checkTextArray() 57 final int[] res = mResources.getIntArray(resid); in checkIntArray()
|
D | PluralResourcesTest.java | 34 private Resources mResources; field in PluralResourcesTest 39 mResources = mContext.getResources(); in setUp() 44 config.updateFrom(mResources.getConfiguration()); in resourcesForLanguage() 46 return new Resources(mResources.getAssets(), mResources.getDisplayMetrics(), config); in resourcesForLanguage()
|
D | RawResourceTest.java | 28 private Resources mResources; field in RawResourceTest 33 mResources = mContext.getResources(); in setUp() 38 final InputStream is = mResources.openRawResource(R.raw.text); in testReadToEnd()
|
D | FractionTest.java | 27 private Resources mResources; field in FractionTest 33 mResources = mContext.getResources(); in setUp() 78 mResources.getValue(resid, mValue, true); in tryFraction()
|
/cts/tests/tests/provider/src/android/provider/cts/ |
D | ContactsContract_CommonDataKinds_ImTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_ImTest 30 mResources = mContext.getResources(); in setUp() 59 String label = mResources.getString(res); in assertGetProtocolLabel() 60 assertEquals(label, Im.getProtocolLabel(mResources, type, "")); in assertGetProtocolLabel() 66 assertEquals(label, Im.getProtocolLabel(mResources, Im.PROTOCOL_CUSTOM, label)); in assertCustomProtocolLabel() 73 String label = mResources.getString(res); in assertGetTypeLabel() 74 assertEquals(label, Im.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 80 assertEquals(label, Im.getTypeLabel(mResources, Im.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_SipAddressTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_SipAddressTest 30 mResources = mContext.getResources(); in setUp() 45 String label = mResources.getString(res); in assertGetTypeLabel() 46 assertEquals(label, SipAddress.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 52 assertEquals(label, SipAddress.getTypeLabel(mResources, SipAddress.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_StructuredPostalTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_StructuredPostalTest 30 mResources = mContext.getResources(); in setUp() 45 String label = mResources.getString(res); in assertGetTypeLabel() 46 assertEquals(label, StructuredPostal.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 52 assertEquals(label, StructuredPostal.getTypeLabel(mResources, in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_EmailTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_EmailTest 30 mResources = mContext.getResources(); in setUp() 46 String label = mResources.getString(res); in assertGetTypeLabel() 47 assertEquals(label, Email.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 53 assertEquals(label, Email.getTypeLabel(mResources, Email.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_OrganizationTest.java | 29 private Resources mResources; field in ContactsContract_CommonDataKinds_OrganizationTest 34 mResources = mContext.getResources(); in setUp() 48 String label = mResources.getString(res); in assertGetTypeLabel() 49 assertEquals(label, Organization.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 55 assertEquals(label, Organization.getTypeLabel(mResources, Im.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_RelationTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_RelationTest 30 mResources = mContext.getResources(); in setUp() 56 String label = mResources.getString(res); in assertGetTypeLabel() 57 assertEquals(label, Relation.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 63 assertEquals(label, Relation.getTypeLabel(mResources, Relation.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
D | ContactsContract_CommonDataKinds_PhoneTest.java | 25 private Resources mResources; field in ContactsContract_CommonDataKinds_PhoneTest 30 mResources = mContext.getResources(); in setUp() 62 String label = mResources.getString(res); in assertGetTypeLabel() 63 assertEquals(label, Phone.getTypeLabel(mResources, type, "")); in assertGetTypeLabel() 69 assertEquals(label, Phone.getTypeLabel(mResources, Phone.TYPE_CUSTOM, label)); in assertCustomTypeLabel()
|
/cts/tests/tests/preference2/src/android/preference2/cts/ |
D | SwitchPreferenceTest.java | 30 private Resources mResources; field in SwitchPreferenceTest 42 mResources = mActivity.getResources(); in setUp() 47 String titleExp = mResources.getString(R.string.title_switch_preference); in testGetTitle() 53 String summaryExp = mResources.getString(R.string.summary_switch_preference); in testGetSummary() 59 String summaryOnExp = mResources.getString( in testGetSummaryOn() 66 String summaryOffExp = mResources.getString( in testSummaryOff() 83 final CharSequence switchOffExp = mResources.getString( in testSetSwitchTextOff_Two() 101 final CharSequence switchOnExp = mResources.getString( in testSetSwitchTextOn_Two()
|
/cts/tests/tests/graphics/src/android/opengl/cts/ |
D | CompressedTextureCtsActivity.java | 34 protected Resources mResources; field in CompressedTextureCtsActivity 47 mResources = getResources(); in onCreate() 54 Bitmap bitmap = BitmapFactory.decodeResource(mResources, R.raw.basetex, optionsRGB); in onCreate() 59 compressed = CompressedTextureLoader.loadTextureDXT(mResources, R.raw.ddstex); in onCreate() 61 compressed = CompressedTextureLoader.loadTextureATC(mResources, 0); //cts for now in onCreate() 63 compressed = CompressedTextureLoader.loadTexturePVRTC(mResources, R.raw.pvrtex); in onCreate()
|
/cts/tests/tests/graphics/src/android/graphics/drawable/cts/ |
D | DrawableTest.java | 54 Resources mResources; field in DrawableTest 60 mResources = mContext.getResources(); in setUp() 146 source = mResources.openRawResource(R.raw.testimage); in writeSampleImage() 224 assertNull(Drawable.createFromResourceStream(mResources, null, inputEmptyStream, in testCreateFromResourceStream1() 233 assertNotNull(Drawable.createFromResourceStream(mResources, value, inputStream, in testCreateFromResourceStream1() 274 assertNull(Drawable.createFromResourceStream(mResources, null, inputEmptyStream, in testCreateFromResourceStream2() 283 assertNotNull(Drawable.createFromResourceStream(mResources, value, inputStream, in testCreateFromResourceStream2() 306 XmlPullParser parser = mResources.getXml(R.drawable.gradientdrawable); in testCreateFromXml() 307 Drawable drawable = Drawable.createFromXml(mResources, parser); in testCreateFromXml() 310 Drawable expected = mResources.getDrawable(R.drawable.gradientdrawable, null); in testCreateFromXml() [all …]
|
D | AnimatedVectorDrawableTest.java | 55 private Resources mResources; field in AnimatedVectorDrawableTest 76 mResources = mActivity.getResources(); in setUp() 89 String originalFilePath = mResources.getString(resId); in saveVectorDrawableIntoPNG() 114 XmlPullParser parser = mResources.getXml(mResId); in testInflate() 127 drawable.inflate(mResources, parser, attrs); in testInflate() 145 (AnimatedVectorDrawable) mResources.getDrawable(resId); in testSingleFrameAnimation() 209 AnimatedVectorDrawable d1 = (AnimatedVectorDrawable) mResources.getDrawable(mResId); in testMutate() 210 AnimatedVectorDrawable d2 = (AnimatedVectorDrawable) mResources.getDrawable(mResId); in testMutate() 211 AnimatedVectorDrawable d3 = (AnimatedVectorDrawable) mResources.getDrawable(mResId); in testMutate() 237 AnimatedVectorDrawable d1 = (AnimatedVectorDrawable) mResources.getDrawable(mResId); in testGetOpacity() [all …]
|
D | AnimationDrawableTest.java | 50 private Resources mResources; field in AnimationDrawableTest 60 mResources = activity.getResources(); in setUp() 197 Drawable frame = mResources.getDrawable(R.drawable.failed); in testGetNumberOfFrames() 215 Drawable drawable = mResources.getDrawable(R.drawable.testimage); in testGetFrame() 220 drawable = mResources.getDrawable(R.drawable.pass); in testGetFrame() 225 drawable = mResources.getDrawable(R.drawable.scenery); in testGetFrame() 314 dr.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflateCorrect() 333 dr.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflateMissingDrawable() 355 dr.inflate(mResources, null, Xml.asAttributeSet(parser)); in testInflateNullXmlPullParser() 366 dr.inflate(mResources, parser, null); in testInflateNullAttributeSet() [all …]
|
D | StateListDrawableTest.java | 47 private Resources mResources; field in StateListDrawableTest 56 mResources = getInstrumentation().getTargetContext().getResources(); in setUp() 172 final Resources res = mResources; in runPreloadDensityTestForDrawable() 236 mMockDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 257 mMockDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 275 mMockDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 290 mMockDrawable.inflate(mResources, null, Xml.asAttributeSet(parser)); in testInflateWithNullParameters() 296 mMockDrawable.inflate(mResources, parser, null); in testInflateWithNullParameters() 304 (StateListDrawable) mResources.getDrawable(R.drawable.statelistdrawable); in testMutate() 306 (StateListDrawable) mResources.getDrawable(R.drawable.statelistdrawable); in testMutate() [all …]
|
D | NinePatchDrawableTest.java | 67 private Resources mResources; field in NinePatchDrawableTest 72 mResources = getInstrumentation().getTargetContext().getResources(); in setUp() 83 Bitmap bmp = BitmapFactory.decodeResource(mResources, R.drawable.ninepatch_0); in testConstructors() 84 String name = mResources.getResourceName(R.drawable.ninepatch_0); in testConstructors() 158 NinePatchDrawable npd = (NinePatchDrawable) mResources.getDrawable(R.drawable.ninepatch_0); in testGetPadding() 166 npd = (NinePatchDrawable) mResources.getDrawable(R.drawable.ninepatch_1); in testGetPadding() 336 mResources, bitmap, new byte[1000], null, "TESTNAME"); in testInflate() 339 int targetDensity = mResources.getDisplayMetrics().densityDpi; in testInflate() 347 XmlResourceParser parser = mResources.getXml(R.drawable.ninepatchdrawable); in testInflate() 353 ninePatchDrawable.inflate(mResources, parser, attrs); in testInflate() [all …]
|
D | LevelListDrawableTest.java | 40 private Resources mResources; field in LevelListDrawableTest 49 mResources = getInstrumentation().getTargetContext().getResources(); in setUp() 116 mLevelListDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 129 mLevelListDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 139 mLevelListDrawable.inflate(mResources, parser, Xml.asAttributeSet(parser)); in testInflate() 154 mLevelListDrawable.inflate(mResources, null, Xml.asAttributeSet(parser)); in testInflateWithNullParameters() 160 mLevelListDrawable.inflate(mResources, parser, null); in testInflateWithNullParameters()
|
/cts/tests/tests/security/src/android/security/cts/ |
D | MediaMetadataRetrieverTest.java | 29 protected Resources mResources; field in MediaMetadataRetrieverTest 35 mResources = getContext().getResources(); in setUp() 47 AssetFileDescriptor afd = mResources.openRawResourceFd(resid); in setDataSourceFd()
|
/cts/tests/tests/media/src/android/media/cts/ |
D | MediaPlayerSurfaceStubActivity.java | 31 protected Resources mResources; field in MediaPlayerSurfaceStubActivity 40 mResources = getResources(); in onCreate() 44 AssetFileDescriptor afd = mResources.openRawResourceFd(R.raw.testvideo); in onCreate()
|
D | MediaExtractorTest.java | 31 protected Resources mResources; field in MediaExtractorTest 37 mResources = getContext().getResources(); in setUp() 48 AssetFileDescriptor afd = mResources.openRawResourceFd(resid); in getDataSourceFor()
|
D | MediaMetadataRetrieverTest.java | 31 protected Resources mResources; field in MediaMetadataRetrieverTest 37 mResources = getContext().getResources(); in setUp() 49 AssetFileDescriptor afd = mResources.openRawResourceFd(resid); in setDataSourceFd() 60 AssetFileDescriptor afd = mResources.openRawResourceFd(resid); in setDataSourceCallback()
|