Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): bump com.google.truth:truth from 1.1.5 to 1.3.0 #83

Merged
merged 1 commit into from
Jan 22, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Jan 22, 2024

Bumps com.google.truth:truth from 1.1.5 to 1.3.0.

Release notes

Sourced from com.google.truth:truth's releases.

1.3.0

In this release, our assertions on Java 8 types begin to move from the truth-java8-extensions artifact and the Truth8 class to the main truth artifact and the Truth class. This change should not break compatibility for anyone, even users who test under old versions of Android without API desugaring. Additionally, we will never break binary compatibility, though some users will have to make changes to their source code in order for it to compile against newer versions.

This change will be routine for most users, but we're providing as much information as we can for any users who do encounter problems.

We will post fuller instructions for migration later on, once we've learned more from our internal migration efforts. For now, you may find that you need to make one kind of change, and you may elect to make others. (If we missed anything, please open an issue to report problems or request help.)

The change you might need to make:

  • By adding new overloads of Truth.assertThat, we cause some code to fail to compile because of an overload ambiguity. This is rare, but it can happen if you static import both Truth.assertThat and some other assertThat method that includes overloads for Optional or Stream. (It does not happen for Truth8.assertThat, though, except with the Eclipse compiler. Nor it does necessarily happen for other assertThat(Stream) and assertThat(Optional) methods.) If this happens to you, you'll need to remove one of the static imports, changing the corresponding call sites from "assertThat" to "FooSubject.assertThat."
    • Alternatively, you may choose to wait until we make further changes to the new Truth.assertThat overloads. Once we make those further changes, you may be able to simultaneously replace all your imports of Truth8.assertThat with imports of Truth.assertThat as you upgrade to the new version, likely without introducing overload ambiguities.

The changes you might elect to make:

  • If you use Truth8.assertThat(Stream) or Truth8.assertThat(Optional), you can migrate to the new overloads in Truth. If you static import Truth8.assertThat, you can usually make this change simply by replacing that static import with a static import of Truth.assertThat—or, if you already have an import of Truth.assertThat, by just removing the import of Truth8.assertThat. (If you additionally use less common assertion methods, like assertThat(OptionalInt), you'll want to use both imports for now. Later, we'll move assertThat(OptionalInt) and friends, too.) We recommend making this change now, since your calls to Truth8.assertThat will fail to compile against some future version of Truth, unless you plan to wait to update your Truth dependency until we've made all our changes for Java 8 types.

  • If you use assertWithMessage(...).about(streams()).that(...), expect.about(optionals()).that(...), or similar, you can remove your call to about. This change will never be necessary; it is just a simplification.

  • If you depend on truth-java8-extension, you may remove it. All its classes are now part of the main truth artifact. This change, too, is not necessary; it is just a simplification. (OK, if your build system has a concept of strict deps, there is a chance that you'll need to add deps on truth to replace your deps on truth-java8-extension.)

Finally, the changelog for this release:

  • Made StreamSubject avoid collecting the Stream until necessary, and made its isEqualTo and isNotEqualTo methods no longer always throw. (f8ecaec69)
  • Added assertThat overloads for Optional and Stream to the main Truth class. (37fd8bea9)
  • Added that overloads to make it possible to write type-specific assertions when using expect.that(optional) and expect.that(stream). (ca7e8f4c5)
  • Moved the truth-java8-extension classes into the main truth artifact. There is no longer any need to depend on truth-java8-extension, which is now empty. (We've also removed the Truth8 GWT module.) (eb0426eb7)

Again, if you have any problems, please let us know.

1.2.0

  • Fixed a bug that caused ProtoTruth to ignore the contents of unpacked Any messages. This fix may cause tests to fail, since ProtoTruth will now check whether the message contents match. If so, you may need to change the values that your tests expect, or there may be a bug in the code under test that had been hidden by the Truth bug. Sorry for the trouble. (8bd3ef613)
  • Added isWithin().of() support to IntegerSubject and LongSubject. (6464cb5ca, 0e99a2711)
Commits
  • abf9e15 Set version number for truth-parent to 1.3.0.
  • 93b4d93 Add @since tags for the first batch of Java-8-related APIs.
  • 78d27dd Remove stale suppressions.
  • 7be930d Bump actions/cache from 3.3.3 to 4.0.0
  • 16db780 Make "value of" lines work with StreamSubject.
  • 37fd8be Copy Truth8.assertThat overloads for Optional and Stream to the main `T...
  • ca7e8f4 Make it possible to write expect.that(optional).isPresent(), `assertWithMes...
  • f8ecaec Prepare StreamSubject for adding Truth.assertThat(Stream).
  • 795a9cf Bump actions/cache from 3.3.2 to 3.3.3
  • 7dab78f Bump com.google.protobuf:protobuf-java from 3.25.1 to 3.25.2
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore <dependency name> major version will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself)
  • @dependabot ignore <dependency name> minor version will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself)
  • @dependabot ignore <dependency name> will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself)
  • @dependabot unignore <dependency name> will remove all of the ignore conditions of the specified dependency
  • @dependabot unignore <dependency name> <ignore condition> will remove the ignore condition of the specified dependency and ignore conditions

Bumps [com.google.truth:truth](https://github.com/google/truth) from 1.1.5 to 1.3.0.
- [Release notes](https://github.com/google/truth/releases)
- [Commits](google/truth@v1.1.5...v1.3.0)

---
updated-dependencies:
- dependency-name: com.google.truth:truth
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
@azrael8576 azrael8576 merged commit d694f08 into main Jan 22, 2024
4 checks passed
@dependabot dependabot bot deleted the dependabot/gradle/com.google.truth-truth-1.3.0 branch January 22, 2024 05:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant