codeconsole commented on PR #15934: URL: https://github.com/apache/grails-core/pull/15934#issuecomment-4929933811
Correcting my Mongo OSIV test (it broke the MongoDB Functional Tests job): the `OpenSessionInViewSpec` I added to `grails-test-examples/mongodb/base` asserted a bean that app never registers — the Mongo OSIV class lives in `grails-datastore-web`, which mongodb/base doesn't depend on — so it failed against real Mongo. I've removed it. @wbduque's `MongoOpenSessionInViewSpec` (grails-data-mongodb/core, Testcontainers via `AutoStartedMongoSpec`) is the right coverage here — it exercises `MongoDbDataStoreSpringInitializer.isWebApplicationRegistry()` against a real `GenericWebApplicationContext` with no `dispatcherServlet` yet, plus a non-web control. Thanks for that; merged it in. I also kept a small complementary unit test (`AbstractDatastoreInitializerWebApplicationSpec`) covering the shared method's other branches — null registry and the legacy `dispatcherServlet` signal — with no Docker needed. Between the two, plus the Hibernate OSIV integration tests, the `isWebApplicationRegistry()` fix is covered on all branches. -- 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]
