jamesfredley commented on code in PR #15685:
URL: https://github.com/apache/grails-core/pull/15685#discussion_r3314889628
##########
grails-data-mongodb/core/src/test/groovy/org/grails/datastore/gorm/mongo/DisjunctionQuerySpec.groovy:
##########
@@ -18,20 +18,21 @@
*/
package org.grails.datastore.gorm.mongo
-import grails.gorm.tests.Pet
+import org.apache.grails.data.mongo.core.MongoDatastoreSpec
+
+import grails.gorm.specs.Pet
import org.apache.grails.data.testing.tck.domains.PetType
-import org.apache.grails.data.mongo.core.GrailsDataMongoTckManager
-import org.apache.grails.data.testing.tck.base.GrailsDataTckSpec
+
import spock.lang.Issue
-class DisjunctionQuerySpec extends
GrailsDataTckSpec<GrailsDataMongoTckManager> {
+class DisjunctionQuerySpec extends MongoDatastoreSpec {
def dogType
def catType
def birdType
void setupSpec() {
- manager.domainClasses += [Pet, PetType]
+ manager.addAllDomainClasses([Pet, PetType])
Review Comment:
Fixed in b5a7aa7625 - good catch. The `addAllDomainClasses` helper only
exists in #15683 (PR-C), not on 8.0.x. The setupSpec calls were inherited from
the staging branch where both changes coexisted. Converted to
`manager.domainClasses.addAll(...)` to make PR-E self-contained against 8.0.x.
Verified with `./gradlew :grails-data-mongodb-core:compileTestGroovy`.
##########
grails-data-mongodb/core/src/test/groovy/org/grails/datastore/gorm/mongo/EmbeddedHasManyWithBeforeUpdateSpec.groovy:
##########
@@ -18,15 +18,16 @@
*/
package org.grails.datastore.gorm.mongo
+import org.apache.grails.data.mongo.core.MongoDatastoreSpec
+
import grails.persistence.Entity
import org.apache.grails.data.mongo.core.GrailsDataMongoTckManager
-import org.apache.grails.data.testing.tck.base.GrailsDataTckSpec
import org.bson.types.ObjectId
-class EmbeddedHasManyWithBeforeUpdateSpec extends
GrailsDataTckSpec<GrailsDataMongoTckManager> {
+class EmbeddedHasManyWithBeforeUpdateSpec extends MongoDatastoreSpec {
void setupSpec() {
- manager.domainClasses += [User, UserAddress]
+ manager.addAllDomainClasses([User, UserAddress])
Review Comment:
Fixed in b5a7aa7625 - good catch. The `addAllDomainClasses` helper only
exists in #15683 (PR-C), not on 8.0.x. The setupSpec calls were inherited from
the staging branch where both changes coexisted. Converted to
`manager.domainClasses.addAll(...)` to make PR-E self-contained against 8.0.x.
Verified with `./gradlew :grails-data-mongodb-core:compileTestGroovy`.
##########
grails-data-mongodb/core/src/test/groovy/org/grails/datastore/gorm/mongo/EmbeddedWithIdSpecifiedSpec.groovy:
##########
@@ -18,14 +18,15 @@
*/
package org.grails.datastore.gorm.mongo
+import org.apache.grails.data.mongo.core.MongoDatastoreSpec
+
import grails.persistence.Entity
import org.apache.grails.data.mongo.core.GrailsDataMongoTckManager
-import org.apache.grails.data.testing.tck.base.GrailsDataTckSpec
-class EmbeddedWithIdSpecifiedSpec extends
GrailsDataTckSpec<GrailsDataMongoTckManager> {
+class EmbeddedWithIdSpecifiedSpec extends MongoDatastoreSpec {
void setupSpec() {
- manager.domainClasses += [SystemCustomer, PreorderTreeNode,
MultiLevelKpi]
+ manager.addAllDomainClasses([SystemCustomer, PreorderTreeNode,
MultiLevelKpi])
Review Comment:
Fixed in b5a7aa7625 - good catch. The `addAllDomainClasses` helper only
exists in #15683 (PR-C), not on 8.0.x. The setupSpec calls were inherited from
the staging branch where both changes coexisted. Converted to
`manager.domainClasses.addAll(...)` to make PR-E self-contained against 8.0.x.
Verified with `./gradlew :grails-data-mongodb-core:compileTestGroovy`.
##########
grails-data-mongodb/core/src/test/groovy/org/grails/datastore/gorm/mongo/GetAllSpec.groovy:
##########
@@ -18,19 +18,19 @@
*/
package org.grails.datastore.gorm.mongo
-import grails.gorm.tests.Pet
-import grails.gorm.tests.Person
+import org.apache.grails.data.mongo.core.MongoDatastoreSpec
+
+import grails.gorm.specs.Pet
+import grails.gorm.specs.Person
import org.apache.grails.data.testing.tck.domains.PetType
-import org.apache.grails.data.mongo.core.GrailsDataMongoTckManager
-import org.apache.grails.data.testing.tck.base.GrailsDataTckSpec
/**
* @author Graeme Rocher
*/
-class GetAllSpec extends GrailsDataTckSpec<GrailsDataMongoTckManager> {
+class GetAllSpec extends MongoDatastoreSpec {
void setupSpec() {
- manager.domainClasses += [Pet, Person, PetType]
+ manager.addAllDomainClasses([Pet, Person, PetType])
Review Comment:
Fixed in b5a7aa7625 - good catch. The `addAllDomainClasses` helper only
exists in #15683 (PR-C), not on 8.0.x. The setupSpec calls were inherited from
the staging branch where both changes coexisted. Converted to
`manager.domainClasses.addAll(...)` to make PR-E self-contained against 8.0.x.
Verified with `./gradlew :grails-data-mongodb-core:compileTestGroovy`.
##########
grails-data-mongodb/core/src/test/groovy/org/grails/datastore/gorm/mongo/HintQueryArgumentSpec.groovy:
##########
@@ -18,18 +18,18 @@
*/
package org.grails.datastore.gorm.mongo
+import org.apache.grails.data.mongo.core.MongoDatastoreSpec
+
import com.mongodb.MongoException
import com.mongodb.MongoQueryException
import grails.gorm.CriteriaBuilder
import grails.gorm.DetachedCriteria
-import grails.gorm.tests.Person
-import org.apache.grails.data.mongo.core.GrailsDataMongoTckManager
-import org.apache.grails.data.testing.tck.base.GrailsDataTckSpec
+import grails.gorm.specs.Person
-class HintQueryArgumentSpec extends
GrailsDataTckSpec<GrailsDataMongoTckManager> {
+class HintQueryArgumentSpec extends MongoDatastoreSpec {
void setupSpec() {
- manager.domainClasses += [Person]
+ manager.addAllDomainClasses([Person])
Review Comment:
Fixed in b5a7aa7625 - good catch. The `addAllDomainClasses` helper only
exists in #15683 (PR-C), not on 8.0.x. The setupSpec calls were inherited from
the staging branch where both changes coexisted. Converted to
`manager.domainClasses.addAll(...)` to make PR-E self-contained against 8.0.x.
Verified with `./gradlew :grails-data-mongodb-core:compileTestGroovy`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]