Skip to content

refactor(build): consolidate integrationTest sources into test #298

@rstata

Description

@rstata

This issue document commit a51f7d8 from Airbnb, which didn't have a good commit message:

Merges the src/integrationTest source set into src/test for the
tenant/api, tenant/codegen, and tenant/runtime modules, removing
the separate integration-test source set from both the Gradle and Bazel
builds.

Motivation

The integrationTest source set was a historical artifact — the tests
it contained were ordinary JUnit tests that ran in the same JVM as the
unit tests and had no need for a separate source set. Consolidating into
src/test simplifies the build configuration and eliminates the
conceptual overhead of maintaining two parallel test trees.

Changes

Gradle

  • Removed the integrationTest source set and the
    integration-test.gradle.kts convention plugin that wired it up.
  • Merged integrationTest Gradle task dependencies into the standard
    test task.
  • Updated build.gradle.kts files for tenant/api, tenant/codegen,
    and tenant/runtime accordingly.

Bazel

  • Moved all src/integrationTest source files into src/test.
  • Updated all affected BUILD.bazel files so each package's test
    library carries the full union of deps that were previously split
    across the unit-test and integration-test BUILD files.
  • Packages that used the feature_app_codegen macro
    (globalid, execution) now invoke it directly from their
    src/test BUILD file, preserving the same generated-GRT behaviour.
  • Fixed a hardcoded src/integrationTest path reference in
    viaduct_classdiff_test_macro.bzl.
  • Fixed SchemaClassFileDiff to load the default Viaduct schema from
    the correct classpath path in both Gradle (default_schema.graphqls
    at the classpath root) and Bazel (via a new genrule +
    java_library target that renames and re-roots the generated
    @@viaduct_default_schema.graphqls file).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions