This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a commit to branch spring6
in repository https://gitbox.apache.org/repos/asf/causeway.git

commit 915944f90b55961174cbbebcbe0b58dc1aecc8c0
Merge: ef8aebde3c e983ba1702
Author: Andi Huber <[email protected]>
AuthorDate: Fri Mar 1 18:58:38 2024 +0100

    Merge remote-tracking branch 'origin/master' into spring6

 .../img/home/causeway-sticker-76mmx51mm.pdn        | Bin 0 -> 37919 bytes
 .../img/home/causeway-sticker-76mmx51mm.png        | Bin 0 -> 15992 bytes
 .../supplemental-ui/img/home/causeway-sticker.pdf  | Bin 0 -> 19623 bytes
 .../supplemental-ui/img/home/causeway-sticker.pdn  | Bin 0 -> 51512 bytes
 .../supplemental-ui/img/home/causeway-sticker.png  | Bin 0 -> 4066 bytes
 .../supplemental-ui/img/home/causeway-sticker.pptx | Bin 0 -> 41053 bytes
 .../testing/fakedata/applib/services/Integers.java |   5 +-
 .../testing/fakedata/applib/services/Longs.java    |   4 +-
 viewers/graphql/test/pom.xml                       |  75 +----------------
 .../viewer/test/e2e/Abstract_IntegTest.java        |  24 +++++-
 .../test/schema/GqlSchema_print_IntegTest.java     |  89 ---------------------
 .../viewer/test/schema/PrintSchemaIntegTest.java   |  30 +++----
 .../viewer/test/utils/WinMergeGqlDiffReporter.java |  27 -------
 viewers/graphql/testsupport/pom.xml                |  86 ++++++++++++++++++++
 .../CausewayViewerGraphqlIntegTestAbstract.java}   |  75 +++++++++++------
 .../schema/PrintSchemaIntegTestAbstract.java}      |  59 +++++++++-----
 16 files changed, 211 insertions(+), 263 deletions(-)

diff --cc 
viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Abstract_IntegTest.java
index 4b3e922521,b7edeff3fd..a6e78ceb97
--- 
a/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Abstract_IntegTest.java
+++ 
b/viewers/graphql/test/src/test/java/org/apache/causeway/viewer/graphql/viewer/test/e2e/Abstract_IntegTest.java
@@@ -25,14 -32,26 +29,28 @@@ import org.springframework.test.context
  import org.springframework.transaction.annotation.Propagation;
  
  import org.apache.causeway.applib.services.bookmark.BookmarkService;
- import 
org.apache.causeway.viewer.graphql.viewer.test.CausewayViewerGraphqlTestModuleIntegTestAbstract;
 -import 
org.apache.causeway.viewer.graphql.viewer.testsupport.CausewayViewerGraphqlIntegTestAbstract;
++import org.apache.causeway.core.config.CausewayConfiguration;
++import org.apache.causeway.viewer.graphql.viewer.test.domain.UniversityModule;
  import org.apache.causeway.viewer.graphql.viewer.test.domain.dept.Department;
  import 
org.apache.causeway.viewer.graphql.viewer.test.domain.dept.DepartmentRepository;
  import 
org.apache.causeway.viewer.graphql.viewer.test.domain.dept.DeptHeadRepository;
  import 
org.apache.causeway.viewer.graphql.viewer.test.domain.dept.StaffMemberRepository;
++import 
org.apache.causeway.viewer.graphql.viewer.testsupport.CausewayViewerGraphqlIntegTestAbstract;
+ 
  
+ @Import({
+         UniversityModule.class
+ })
+ public abstract class Abstract_IntegTest extends 
CausewayViewerGraphqlIntegTestAbstract {
  
- public abstract class Abstract_IntegTest extends 
CausewayViewerGraphqlTestModuleIntegTestAbstract {
+     protected Abstract_IntegTest() {
+         super(Abstract_IntegTest.class);
+     }
+ 
+     @DynamicPropertySource
 -    static void apiVariant(DynamicPropertyRegistry registry) {
++    static void apiVariant(final DynamicPropertyRegistry registry) {
+         registry.add("causeway.viewer.graphql.api-variant", 
CausewayConfiguration.Viewer.Graphql.ApiVariant.QUERY_WITH_MUTATIONS_NON_SPEC_COMPLIANT::name);
+     }
  
      @Inject protected DepartmentRepository departmentRepository;
      @Inject protected DeptHeadRepository deptHeadRepository;
diff --cc viewers/graphql/testsupport/pom.xml
index 71445418e2,b55b959c2d..cfffa9e547
--- a/viewers/graphql/testsupport/pom.xml
+++ b/viewers/graphql/testsupport/pom.xml
@@@ -60,6 -78,79 +76,76 @@@
  
        <dependencies>
  
+         <dependency>
+             <groupId>org.apache.causeway.viewer</groupId>
+             <artifactId>causeway-viewer-graphql-viewer</artifactId>
+         </dependency>
+ 
+         <dependency>
+             <groupId>org.apache.causeway.core</groupId>
+             <artifactId>causeway-core-internaltestsupport</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.causeway.security</groupId>
+             <artifactId>causeway-security-bypass</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.causeway.core</groupId>
+             <artifactId>causeway-core-runtimeservices</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.causeway.testing</groupId>
+             <artifactId>causeway-testing-fixtures-applib</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.causeway.testing</groupId>
+             <artifactId>causeway-testing-integtestsupport-applib</artifactId>
+         </dependency>
+ 
+         <dependency>
+             <groupId>org.springframework</groupId>
+             <artifactId>spring-context-support</artifactId>
+         </dependency>
+ 
+ 
+         <dependency>
+             <groupId>com.h2database</groupId>
+             <artifactId>h2</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>com.approvaltests</groupId>
+             <artifactId>approvaltests</artifactId>
+         </dependency>
+         <dependency>
+             <groupId>org.apache.causeway.persistence</groupId>
+             <artifactId>causeway-persistence-jpa-eclipselink</artifactId>
+             <exclusions>
+                 <exclusion>
+                     <groupId>org.eclipse.persistence</groupId>
+                     <artifactId>jakarta.persistence</artifactId>
+                 </exclusion>
+             </exclusions>
+         </dependency>
+         <dependency>
+             <groupId>org.springframework.boot</groupId>
+             <artifactId>spring-boot-test-autoconfigure</artifactId>
+         </dependency>
+ 
 -
 -
+         <dependency>
+             <groupId>org.springframework.graphql</groupId>
+             <artifactId>spring-graphql-test</artifactId>
 -            <version>1.2.5</version>
+         </dependency>
+ 
+         <dependency>
+             <groupId>com.github.gavlyukovskiy</groupId>
+             <artifactId>datasource-proxy-spring-boot-starter</artifactId>
+         </dependency>
+ 
+         <dependency>
+             <groupId>com.github.vertical-blank</groupId>
+             <artifactId>sql-formatter</artifactId>
+         </dependency>
+ 
      </dependencies>
  
  </project>
diff --cc 
viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/CausewayViewerGraphqlIntegTestAbstract.java
index ba93c44a1c,ea08553319..740a42ca44
--- 
a/viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/CausewayViewerGraphqlIntegTestAbstract.java
+++ 
b/viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/CausewayViewerGraphqlIntegTestAbstract.java
@@@ -185,17 -212,17 +212,17 @@@ public abstract class CausewayViewerGra
      }
  
      @SneakyThrows
--    protected String submit(Map<String,String> replacements) {
++    protected String submit(final Map<String,String> replacements) {
          val httpRequest = buildRequest(testInfo, "._.gql", replacements);
          return submitRequest(httpRequest);
      }
  
--    protected String submit(String variant) {
++    protected String submit(final String variant) {
          return submit(variant, Collections.emptyMap());
      }
  
      @SneakyThrows
--    protected String submit(String variant, Map<String,String> replacements) {
++    protected String submit(final String variant, final Map<String,String> 
replacements) {
          val httpRequest = buildRequest(testInfo, "._." +variant + ".gql", 
replacements);
          return submitRequest(httpRequest);
      }
@@@ -223,7 -250,7 +250,7 @@@
      }
  
      @SneakyThrows
--    protected HttpRequest buildRequest(String resourceName, Map<String, 
String> replacements) {
++    protected HttpRequest buildRequest(final String resourceName, final 
Map<String, String> replacements) {
          String resourceContents = readResource(resourceName);
          String resourceContent = replace(resourceContents, replacements);
  
@@@ -240,7 -267,7 +267,7 @@@
                  build();
      }
  
--    private static String replace(String str, Map<String, String> 
replacements) {
++    private static String replace(final String str, final Map<String, String> 
replacements) {
          val builder = new StringBuilder(str);
          replacements.forEach((key, value) -> {
              int index;
@@@ -277,15 -304,15 +304,15 @@@
          return jsonOptions(null, BookmarkOptions.SCRUB);
      }
  
--    protected Options jsonOptions(BookmarkOptions bookmarkOptions) {
++    protected Options jsonOptions(final BookmarkOptions bookmarkOptions) {
          return jsonOptions(null, bookmarkOptions);
      }
  
--    public Options jsonOptions(Options options) {
++    public Options jsonOptions(final Options options) {
          return jsonOptions(options, BookmarkOptions.SCRUB);
      }
  
--    public Options jsonOptions(@Nullable Options options, BookmarkOptions 
bookmarkOptions) {
++    public Options jsonOptions(@Nullable Options options, final 
BookmarkOptions bookmarkOptions) {
          if (options == null) {
              options = new Options();
          }
@@@ -339,14 -366,14 +366,14 @@@
  
      protected void afterEach() {}
  
-     protected static Blob asPdfBlob(String fileName) {
 -    protected Blob asPdfBlob(String fileName) {
++    protected Blob asPdfBlob(final String fileName) {
          val bytes = toBytes(fileName);
          return new Blob(fileName, "application/pdf", bytes);
      }
  
      @SneakyThrows
-     protected static byte[] toBytes(String fileName){
-         InputStream inputStream = new ClassPathResource(fileName, 
Abstract_IntegTest.class).getInputStream();
 -    protected byte[] toBytes(String fileName){
++    protected byte[] toBytes(final String fileName){
+         InputStream inputStream = new ClassPathResource(fileName, 
resourceBaseClazz).getInputStream();
          ByteArrayOutputStream buffer = new ByteArrayOutputStream();
  
          int nRead;
diff --cc 
viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/schema/PrintSchemaIntegTestAbstract.java
index a5ffe33a84,3461a27357..6b11d41e61
--- 
a/viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/schema/PrintSchemaIntegTestAbstract.java
+++ 
b/viewers/graphql/testsupport/src/main/java/org/apache/causeway/viewer/graphql/viewer/testsupport/schema/PrintSchemaIntegTestAbstract.java
@@@ -21,9 -21,8 +21,8 @@@ package org.apache.causeway.viewer.grap
  import java.io.File;
  import java.nio.file.Files;
  import java.nio.file.Paths;
- import java.util.stream.Collectors;
  
 -import javax.inject.Inject;
 +import jakarta.inject.Inject;
  
  import graphql.schema.idl.SchemaPrinter;
  

Reply via email to