Skip to content

Releases: takahirom/roborazzi

1.44.0

01 Jun 05:56
62ab157
Compare
Choose a tag to compare

Please refer to https://github.com/takahirom/roborazzi/releases/tag/1.44.0-alpha01 to see the main changes in version 1.44.0. We are still seeking feedback on RoboComposePreviewOptions. RoboComposePreviewOptions is still experimental, and we may introduce breaking changes.

New feature: Added JUnit @Category to auto-generated tests from Compose Preview

You can now filter tests using JUnit4's RoborazziComposePreviewTestCategory. Thanks to @hellohj for the suggestion.

Bugfix: Subdirectory screenshots are now removed when roborazzi.cleanupOldScreenshots=true

Previously, when roborazzi.cleanupOldScreenshots=true was used, subdirectory screenshots were not removed as intended. Thanks to @pacoalface-jt for reporting the bug.

What's Changed

  • Support RoboComposePreviewOptions to support manual clock by @sergio-sastre in #633
  • Downgrade Java target version to 11 and add javadoc generation to CI workflow by @takahirom in #666
  • Rename debugLog to roborazziDebugLog and update usages across the codebase by @takahirom in #668
  • Update JetBrains/writerside-github-action digest to 4d78a74 by @renovate in #660
  • Fix Gemini OpenAI compatibility API by @takahirom in #671
  • Improve compose config performance for Compose Preview Support by @takahirom in #667
  • Update actions/download-artifact digest to 95815c3 by @renovate in #670
  • Update actions/upload-artifact digest to ea165f8 by @renovate in #672
  • Introduce Ollama support for roborazzi-ai-openai by @takahirom in #674
  • Make temperature and maxTokens nullable because they are not used in thinking models. by @takahirom in #676
  • Replace JvmAnnotationScanner with CommonComposablePreviewScanner + add example with @PreviewParameters by @sergio-sastre in #678
  • Update AGP 8.7.3 by @takahirom in #679
  • Configure Gradle to publish to Central Portal by @takahirom in #683
  • Try using walkTopDown instead of listFiles for cleanup by @takahirom in #685
  • Add failing whenRemoveSubdirectoryTestTheOldScreenshotShouldBeRemoved by @takahirom in #686
  • Add RoborazziComposePreviewTestCategory to preview tests by @takahirom in #680

Full Changelog: 1.43.1...1.44.0

1.44.0-alpha04

11 May 04:47
401a373
Compare
Choose a tag to compare

Example update for Compose Multiplatform

The Roborazzi sample for the Compose Multiplatform @Preview annotation has been updated to use CommonComposablePreviewScanner. Thanks to @sergio-sastre for this contribution!

Central Portal Migration

This migration to the Central Portal should not affect users. We've made this change because the previous publishing service (Sonatype OSSRH) is being sunset.

What's Changed

  • [NO library dependency change]Replace JvmAnnotationScanner with CommonComposablePreviewScanner + add example with @PreviewParameters by @sergio-sastre in #678
  • [NO library dependency change]Update AGP 8.7.3 by @takahirom in #679
  • Configure Gradle to publish to Central Portal by @takahirom in #683

Full Changelog: 1.44.0-alpha03...1.44.0-alpha04

1.44.0-alpha03

24 Apr 12:45
70abf03
Compare
Choose a tag to compare

Bugfixes and breaking changes for AI powered Assertion.

OpenAiAiAssertionModel's JsonSchemaType is renamed to ApiType. I realized we needed to adjust other areas beyond JsonSchema, so I renamed it.

Ollama Support

We’ve tried using local LLMs like Gemma in GitHub Actions. It’s not stable yet. If you have GPU servers, using it in a CI server seems feasible. I suggest checking the MMMU benchmark score, and a score of 65 or higher would be desirable.

You can use it like this.

          aiAssertionOptions = AiAssertionOptions(
            assertionImageType = AiAssertionOptions.AssertionImageType.Actual(),
            aiAssertionModel = OpenAiAiAssertionModel(
//              loggingEnabled = true,
              baseUrl = "http://localhost:11434/v1/",
              apiKey = "",
              apiType = OpenAiAiAssertionModel.ApiType.Ollama,
              modelName = "gemma3:4b-it-qat",
              seed = null,
            ),
          )

Bugfix for reasoning models

When using Azure OpenAI API's reasoning models, I encountered errors when passing temperature and max_tokens. I resolved this by making these parameters nullable to avoid passing them when not needed.

What's Changed

  • Update actions/download-artifact digest to 95815c3 by @renovate in #670
  • Update actions/upload-artifact digest to ea165f8 by @renovate in #672
  • Introduce Ollama support for roborazzi-ai-openai by @takahirom in #674
  • Make temperature and maxTokens nullable because they are not used in thinking models. by @takahirom in #676

Full Changelog: 1.44.0-alpha02...1.44.0-alpha03

1.44.0-alpha02

05 Apr 09:31
34ad558
Compare
Choose a tag to compare

Small fixes

  • We had a top-level function named debugLog(), but since it is not intended for public use, we have deprecated it and renamed it to roborazziDebugLog().
  • We used to call RuntimeEnvironment.setQualifiers() multiple times within a single test in Compose Preview Support. However, since this can negatively impact performance, we have consolidated the calls into a single invocation. This change may result in different images. If you notice any differences and they are problematic, please let us know.
  • Gemini's JSON Schema validation appears to have become stricter recently, so we made some adjustments to the JSON schema used for Gemini.

What's Changed

  • Rename debugLog to roborazziDebugLog() and update usages across the codebase by @takahirom in #668
  • [CI] Update JetBrains/writerside-github-action digest to 4d78a74 by @renovate in #660
  • Fix Gemini OpenAI compatibility API by @takahirom in #671
  • Improve compose config performance for Compose Preview Support by @takahirom in #667

Full Changelog: 1.44.0-alpha01...1.44.0-alpha02

1.44.0-alpha01

22 Mar 08:24
76812e8
Compare
Choose a tag to compare

Why is this an alpha release?

We don't usually release an alpha version. This release serves as a base implementation for future versions, allowing us to test whether this approach works well across various projects. If you are using Experimental Compose Preview Support, please try it out and provide feedback to help us improve it.

Introducing RoboComposePreviewOptions for Experimental Compose Preview Support

We have received a great deal of feedback regarding Experimental Compose Preview Support—particularly concerning animated composables such as the CircularProgressIndicator, which animates endlessly and causes test timeout errors. Previously, developers had to comment out code or implement complex workarounds. In this release, we introduce RoboComposePreviewOptions to address these issues, although it involves some breaking changes. To use RoboComposePreviewOptions, you need to add the new roborazzi-annotations dependency. If you do not use Experimental Compose Preview Support, please refer to Experimental Compose Preview Support.

Thanks to @sergio-sastre for contributing to the base implementation. These changes also pave the way for future customizations in Roborazzi.

@RoboComposePreviewOptions(
  manualClockOptions = [
    ManualClockOptions(
      advanceTimeMillis = 0L,
    ),
    ManualClockOptions(
      advanceTimeMillis = 516L,  // 500 ms + 16ms frame
    ),
    ManualClockOptions(
      advanceTimeMillis = 1032L,
    ),
  ]
)
@Preview
@Composable
fun PreviewDelayed() {
    ...
}

clipboard-image-1742618350

Breaking changes for Experimental Compose Preview Support's ComposePreviewTester users

Key interface changes

  1. ComposePreviewTester now handles TestParameter instead of raw ComposablePreview.
  2. A new @RoboComposePreviewOptions annotation enables time-based captures.
  3. The roborazzi-annotations module has been added as a new dependency.

Migration

Update custom testers:

// Before
class CustomTester : ComposePreviewTester<AndroidPreviewInfo> {
  override fun previews(): ComposablePreview<AndroidPreviewInfo> = AndroidComposablePreviewScanner().scanPackageTrees(...)
  override fun test(preview: ComposablePreview<AndroidPreviewInfo>)
}

// After
class CustomTester : ComposePreviewTester<AndroidPreviewJUnit4TestParameter> {
  override fun testParameters(): AndroidPreviewJUnit4TestParameter = AndroidComposablePreviewScanner().scanPackageTrees(...)
  override fun test(preview: AndroidPreviewJUnit4TestParameter)
}

Sample implementations

What's Changed

  • Support RoboComposePreviewOptions to support manual clock by @sergio-sastre in #633
  • Downgrade Java target version to 11 and add javadoc generation to CI workflow by @takahirom in #666

Full Changelog: 1.43.1...1.44.0-alpha01

1.43.1

20 Mar 02:20
785ea45
Compare
Choose a tag to compare

We added error handling for font availability checks in 1.43.0. However, it seems that the "font not available" error is an Error rather than an Exception, so we updated the code to handle Throwable.

What's Changed

  • [No Roborazzi library dependency update] Update dependency androidx.compose.ui:ui-tooling-preview to v1.7.8 by @renovate in #643
  • Handle font availability errors by catching Throwable by @takahirom in #665

Full Changelog: 1.43.0...1.43.1

1.43.0

27 Feb 01:02
9bedf3a
Compare
Choose a tag to compare

Bugfix

Added error handling for font availability checks in headless environments, falling back to Font.MONOSPACED when preferred fonts are unavailable. Thanks for reporting this issue @pavel163

What's Changed

  • [No Roborazzi library dependency update]Update dependency androidx.compose.foundation:foundation to v1.7.8 by @renovate in #620
  • Fix font crash by @takahirom in #661

Full Changelog: 1.42.0...1.43.0

1.42.0

16 Feb 04:46
4b9f3cd
Compare
Choose a tag to compare

Bug fixes

We are using the "Courier New" font for comparison image text and screenshot dumps. It appears that "Courier New" is not available in CentOS, although this may not be an issue for Mac, Ubuntu, and Windows users.

To address this problem, we have introduced two mechanisms. Thank you for reporting this issue, @LloydBlv.

  • Added a fallback to Font.MONOSPACED to ensure execution when the font exists
  • Made the font customizable through roborazzi.theme.typography.font.name=Your Font Name

What's Changed

  • Fix issue where Roborazzi crash when the font is not available by @takahirom in #657

Full Changelog: 1.41.1...1.42.0

1.41.1

12 Feb 10:47
4a1c149
Compare
Choose a tag to compare

In some cases, the new test result format breaks the report's HTML/JS. Thank for fixing this, @unni-dm!

What's Changed

  • Fix for HTML result will break when context data key has special char… by @unni-dm in #654

New Contributors

Full Changelog: 1.41.0...1.41.1

1.41.0

11 Feb 03:28
777f8c7
Compare
Choose a tag to compare

HTML Report Improvements

Thanks to @mannodermaus's contribution, context and AI assertion results now display more intuitively instead of showing raw data class toString() outputs.
image

Bug Fixes

  • Screenshot dumping now follows deterministic behavior thanks to @siarhei-luskanau's implementation

Automatic Retry Handling for 429 Errors

(Only relevant for arbigent-ai-openai users)
We've implemented automatic retry logic for HTTP 429 errors common with AI model rate limits, eliminating manual intervention.

Experimental Multi-Image AI Assertion

Originally developed for Arbigent, this feature now supports multi-image inputs for AI assertions - enabling detection of video playback or animated content through AI analysis.

What's Changed

  • Print collection content in ComposePrintToString to stabilize output in Dump screenshots. by @siarhei-luskanau in #642
  • [NO Library update] Update dependency androidx.compose.ui:ui to v1.7.6 by @renovate in #345
  • Update formatting of left column in reports by @mannodermaus in #644
  • [NO Library update] Remove upload artifact for docs by @takahirom in #648
  • [NO Library update] Update upload-pages-artifact by @takahirom in #649
  • [NO Library update] Update actions/deploy-pages by @takahirom in #650
  • Add multiple image assertion by @takahirom in #651
  • Add OpenAiAiAssertionModel 429 retry logic by @takahirom in #653

Full Changelog: 1.40.1...1.41.0