airbnb / Showkase

🔦 Showkase is an annotation-processor based Android library that helps you organize, discover, search and visualize Jetpack Compose UI elements

Home Page:https://medium.com/airbnb-engineering/introducing-showkase-a-library-to-organize-discover-and-visualize-your-jetpack-compose-elements-d5c34ef01095

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Paparazzi not work

drdla49 opened this issue · comments

I used Showkase 1.0.0-beta18 and Paparazzi 1.2.0 in my android app.

I add this to my app build.gradle
classpath("app.cash.paparazzi:paparazzi-gradle-plugin:1.2.0")

This to my Showkase module

plugins {
    id("app.cash.paparazzi")
}

dependencies {
    debugImplementation("com.airbnb.android:showkase:1.0.0-beta18")
    testImplementation("com.airbnb.android:showkase-screenshot-testing-paparazzi:1.0.0-beta18")
    ....
}

apply plugin: "app.cash.paparazzi"

Then run this command
./gradlew recordPaparazziSampleDebug

The result of the command is success but there is no screenshot and no file in folder that is write in terminal.
See the Paparazzi report at: file:///C:/android/Samle/showkase/build/reports/paparazzi/index.html

What am I doing wrong? Thanks for answer

Did you make sure that you added the showkase-processor dependencies as well? It's part of the setup instructions for Showkase. Look at the Paparazzi sample to understand the dependencies you'd need

https://github.com/airbnb/Showkase/blob/master/showkase-screenshot-testing-paparazzi-sample/build.gradle#L132

Thanks for your answer. I add showkase-procesor and now it is trying to create the screenshots.
But every screenshot end with this message:
cz.sample.base.utils.showkase.Test1PaparazziShowkaseScreenshotTest_PaparazziShowkaseTest > test_previews[WidgetMisc**Rating Bar**Full,Pixel5,Ltr,DEFAULT] FAILED java.io.FileNotFoundException at Test1PaparazziShowkaseScreenshotTest_PaparazziShowkaseTest.kt:41

TestLogger:test_previews[WidgetMisc**Rating Bar**Half no count no text,Pixel5,Ltr,DEFAULT] FAILURE (63ms)

Would you happen to have any suggestions? Thank

@drdla49 Perhaps this thread in Paparazzi could be of some help?

@iamutkarshtiwari @drdla49 Was there any clues on what might be causing it? Would appreciate some help if someone can point me to the root cause. Open to fixing it if I can get an easy way to repro (maybe a sample project with a repro?)

Closing due to inactivity as others have been successfully and reliably using Showkase + Paparazzi