= PrintSchemaIntegTestAbstract
:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Utility to print out the schema, to `src/test/resources` of the implementing subclass.

IDEs can then detect this and use it to provide intellisense/code-completion for GraphQL queries, eg used by tests.

If the _org.apache.causeway.core.config.CausewayConfiguration.Viewer.Graphql.ApiVariant ApiVariant_ is to be overridden from the framework's default, use for example Spring's @ _DynamicPropertySource_ annotation.

For example:

----
import static org.apache.causeway.core.config.CausewayConfiguration.Viewer.Graphql;

public class PrintSchemaIntegTest extends PrintSchemaIntegTestAbstract {
    _@_ DynamicPropertySource
    static void apiVariant(DynamicPropertyRegistry registry) {
        registry.add(
             "causeway.viewer.graphql.api-variant",
             Graphql.ApiVariant.QUERY_WITH_MUTATIONS_NON_SPEC_COMPLIANT::name);
    }
}
----

== API

[source,java]
.PrintSchemaIntegTestAbstract.java
----
class PrintSchemaIntegTestAbstract {
  PrintSchemaIntegTestAbstract()
}
----

