Skip to content

Commit

Permalink
Bump hibernate-core from 6.1.7.Final to 6.2.0.Final (#3011)
Browse files Browse the repository at this point in the history
* Bump hibernate-core from 6.1.7.Final to 6.2.0.Final

Bumps [hibernate-core](https://github.com/hibernate/hibernate-orm) from 6.1.7.Final to 6.2.0.Final.
- [Release notes](https://github.com/hibernate/hibernate-orm/releases)
- [Changelog](https://github.com/hibernate/hibernate-orm/blob/6.2.0/changelog.txt)
- [Commits](hibernate/hibernate-orm@6.1.7...6.2.0)

---
updated-dependencies:
- dependency-name: org.hibernate.orm:hibernate-core
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

* Fix Hibernate API usage

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Stefano Cordio <stefano_cordio@epam.com>
  • Loading branch information
dependabot[bot] and scordio committed Apr 1, 2023
1 parent 9416bf1 commit 3bb924b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion assertj-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
<dependency>
<groupId>org.hibernate.orm</groupId>
<artifactId>hibernate-core</artifactId>
<version>6.1.7.Final</version>
<version>6.2.0.Final</version>
<scope>test</scope>
<exclusions>
<exclusion>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
import org.assertj.core.api.AssertionInfo;
import org.assertj.core.data.MapEntry;
import org.assertj.core.test.WithPlayerData;
import org.hibernate.collection.spi.CollectionSemantics;
import org.hibernate.collection.spi.PersistentMap;
import org.hibernate.collection.spi.PersistentSortedMap;
import org.hibernate.engine.spi.SharedSessionContractImplementor;
Expand Down Expand Up @@ -83,12 +84,17 @@ private static <K, V, T extends PersistentMap<K, V>> T hibernateMap(Function<Sha
T persistentMap = supplier.apply(session);

CollectionPersister persister = mock(CollectionPersister.class, RETURNS_DEEP_STUBS);
when(persister.getCollectionType().instantiate(0)).thenReturn(innerMapSupplier.get());
when(getCollectionSemantics(persister).instantiateRaw(0, persister)).thenReturn(innerMapSupplier.get());

persistentMap.initializeEmptyCollection(persister);
return persistentMap;
}

@SuppressWarnings("unchecked")
private static CollectionSemantics<Object, ?> getCollectionSemantics(CollectionPersister persister) {
return (CollectionSemantics<Object, ?>) persister.getCollectionSemantics();
}

protected Map<String, String> actual;
protected Failures failures;
protected Maps maps;
Expand Down

0 comments on commit 3bb924b

Please sign in to comment.