anchor.diff:  [[sec:variant-visual]]
   == Visualizing variant information
   
  +=== The Outgoing Variants Report
  +
   Gradle offers a report task called `outgoingVariants` that displays the variants of a project, with their capabilities, attributes and artifacts.
   It is conceptually similar to the `dependencyInsight` <<viewing_debugging_dependencies.adoc#sec:identifying_reason_dependency_selection,reporting task>>.
   
  
positive.code: 
  It also shows _secondary_ variants, which are exclusive to Gradle projects and not published.
  For example, the secondary variant `classes` from `apiElements` is what allows Gradle to skip the JAR creation when compiling against a <<java_library_plugin.adoc#sec:java_library_classes_usage,`java-library` project>>.
  
  [[sec:variant-aware-matching]]
  == Variant aware matching
  
negative.code: Description = Elements of runtime for main.
  
  Capabilities
      - new-java-library:lib:unspecified (default capability)
  Attributes
      - org.gradle.category            = library
      - org.gradle.dependency.bundling = external
      - org.gradle.jvm.version         = 11
      - org.gradle.libraryelements     = jar
      - org.gradle.usage               = java-runtime
  Artifacts
      - build/libs/lib.jar (artifactType = jar)
  
  Secondary Variants (*)
  
      --------------------------------------------------
      Secondary Variant classes
      --------------------------------------------------
          Description = Directories containing compiled class files for main.
  
          Attributes
              - org.gradle.category            = library
              - org.gradle.dependency.bundling = external
              - org.gradle.jvm.version         = 11
              - org.gradle.libraryelements     = classes
              - org.gradle.usage               = java-runtime
          Artifacts
              - build/classes/java/main (artifactType = java-classes-directory)
  
      --------------------------------------------------
      Secondary Variant resources
      --------------------------------------------------
          Description = Directories containing the project's assembled resource files for use at runtime.
  
          Attributes
              - org.gradle.category            = library
              - org.gradle.dependency.bundling = external
              - org.gradle.jvm.version         = 11
              - org.gradle.libraryelements     = resources
              - org.gradle.usage               = java-runtime
          Artifacts
              - build/resources/main (artifactType = java-resources-directory)
  
  --------------------------------------------------
  Variant testResultsElementsForTest (i)
  --------------------------------------------------
  Description = Directory containing binary results of running tests for the test Test Suite's test target.
  
  Capabilities
      - new-java-library:lib:unspecified (default capability)
  Attributes
      - org.gradle.category              = verification
      - org.gradle.testsuite.name        = test
      - org.gradle.testsuite.target.name = test
      - org.gradle.testsuite.type        = unit-test
      - org.gradle.verificationtype      = test-results
  Artifacts
      - build/test-results/test/binary (artifactType = directory)
  
  (i) Configuration uses incubating attributes such as Category.VERIFICATION.
  (*) Secondary variants are variants created via the Configuration#getOutgoing(): ConfigurationPublications API which also participate in selection, in addition to the configuration itself.
  ----
  
  