Android.Test.Mock.MockContentResolver Class

Developer Guides

See Also: MockContentResolver Members

Syntax

[Android.Runtime.Register("android/test/mock/MockContentResolver", DoNotGenerateAcw=true)]
public class MockContentResolver : Android.Content.ContentResolver

Remarks

Developer Guides

An extension of Android.Content.ContentResolver that is designed for testing.

MockContentResolver overrides Android's normal way of resolving providers by authority. To have access to a provider based on its authority, users of MockContentResolver first instantiate the provider and use MockContentResolver.AddProvider(string, Android.Content.ContentProvider). Resolution of an authority occurs entirely within MockContentResolver.

Users can also set an authority's entry in the map to null, so that a provider is completely mocked out.

For more information about application testing, read the Testing developer guide.

[Android Documentation]

Requirements

Namespace: Android.Test.Mock
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1