Package-level declarations

Types

Link copied to clipboard
class DeviceConfig(val screenHeight: Int = 1280, val screenWidth: Int = 768, val xdpi: Int = 320, val ydpi: Int = 320, val orientation: ScreenOrientation = ScreenOrientation.PORTRAIT, val uiMode: UiMode = UiMode.NORMAL, val nightMode: NightMode = NightMode.NOTNIGHT, val density: Density = Density.XHIGH, val fontScale: Float = 1.0f, val layoutDirection: LayoutDirection = LayoutDirection.LTR, val locale: String? = null, val ratio: ScreenRatio = ScreenRatio.NOTLONG, val size: ScreenSize = ScreenSize.NORMAL, val keyboard: Keyboard = Keyboard.NOKEY, val touchScreen: TouchScreen = TouchScreen.FINGER, val keyboardState: KeyboardState = KeyboardState.SOFT, val softButtons: Boolean = true, val navigation: Navigation = Navigation.NONAV, val screenRound: ScreenRound? = null, val released: String = "November 13, 2012")

Provides FolderConfiguration and HardwareConfig for various devices. Also provides utility methods to parse build.prop and attrs.xml to generate the appropriate maps.

Link copied to clipboard
class Environment(val appTestDir: String, val packageName: String, val compileSdkVersion: Int, val resourcePackageNames: List<String>, val localResourceDirs: List<String>, val moduleResourceDirs: List<String>, val libraryResourceDirs: List<String>, val allModuleAssetDirs: List<String>, val libraryAssetDirs: List<String>)
Link copied to clipboard
object Flags
Link copied to clipboard
class HtmlReportWriter @JvmOverloads constructor(runName: String = defaultRunName(), rootDirectory: File = File(System.getProperty("paparazzi.report.dir")), snapshotRootDirectory: File = File(System.getProperty("paparazzi.snapshot.dir"))) : SnapshotHandler

Creates an HTML report that avoids writing files that have already been written.

Link copied to clipboard
class InstantAnimationsRule : TestRule

Sets animation duration scale to 0 so all animations run instantly. Use this with Paparazzi to skip animations and snapshot their terminal state.

Link copied to clipboard
class Paparazzi @JvmOverloads constructor(environment: Environment = detectEnvironment(), deviceConfig: DeviceConfig = DeviceConfig.NEXUS_5, theme: String = "android:Theme.Material.NoActionBar.Fullscreen", renderingMode: SessionParams.RenderingMode = RenderingMode.NORMAL, appCompatEnabled: Boolean = true, maxPercentDifference: Double = detectMaxPercentDifferenceDefault(), snapshotHandler: SnapshotHandler = determineHandler(maxPercentDifference), renderExtensions: Set<RenderExtension> = setOf(), supportsRtl: Boolean = false, showSystemUi: Boolean = false, validateAccessibility: Boolean = false, useDeviceResolution: Boolean = false) : TestRule
Link copied to clipboard
class PaparazziSdk @JvmOverloads constructor(environment: Environment = detectEnvironment(), deviceConfig: DeviceConfig = DeviceConfig.NEXUS_5, theme: String = "android:Theme.Material.NoActionBar.Fullscreen", renderingMode: SessionParams.RenderingMode = RenderingMode.NORMAL, appCompatEnabled: Boolean = true, renderExtensions: Set<RenderExtension> = setOf(), supportsRtl: Boolean = false, showSystemUi: Boolean = false, validateAccessibility: Boolean = false, useDeviceResolution: Boolean = false, onNewFrame: (BufferedImage) -> Unit)
Link copied to clipboard
interface RenderExtension

An extension for overlaying additional information on top of each rendered frame.

Link copied to clipboard
class Snapshot(val name: String?, val testName: TestName, val timestamp: Date, val tags: List<String> = listOf(), val file: String? = null)
Link copied to clipboard
Link copied to clipboard
class SnapshotVerifier @JvmOverloads constructor(maxPercentDifference: Double, rootDirectory: File = File(System.getProperty("paparazzi.snapshot.dir"))) : SnapshotHandler
Link copied to clipboard
class TestName(val packageName: String, val className: String, val methodName: String)

Functions