Skip to content

Commit

Permalink
reenable canton tests every day (#16765)
Browse files Browse the repository at this point in the history
This is obviously not going to do anything until some tests have the
tag.
  • Loading branch information
garyverhaegen-da committed Apr 27, 2023
1 parent 1366b36 commit 1f3c22c
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 4 deletions.
8 changes: 8 additions & 0 deletions build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,15 @@ if ($env:SKIP_TESTS -ceq "False") {
./ci/remap-scala-test-short-names.ps1 `
| Out-File -Encoding UTF8 -NoNewline scala-test-suite-name-map.json

$skip_dev_canton = "True"
$tag_filter = ""
if ($skip_dev_canton -ceq "True") {
$tag_filter = "-dev-canton-test"
}

bazel test //... `
`-`-build_tag_filters "$tag_filter" `
`-`-test_tag_filters "$tag_filter" `
`-`-profile test-profile.json `
`-`-experimental_profile_include_target_label `
`-`-build_event_json_file test-events.json `
Expand Down
13 changes: 9 additions & 4 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,12 @@ mkdir -p "${ARTIFACT_DIRS}/logs"

tag_filter=""
if [[ "$(uname)" == "Darwin" ]]; then
tag_filter="-dont-run-on-darwin,-scaladoc,-pdfdocs"
tag_filter="$tag_filter,-dont-run-on-darwin,-scaladoc,-pdfdocs"
fi

SKIP_DEV_CANTON_TESTS=true
if [ "$SKIP_DEV_CANTON_TESTS" = "true" ]; then
tag_filter="$tag_filter,-dev-canton-test"
fi

# Occasionally we end up with a stale sandbox process for a hardcoded
Expand All @@ -36,7 +41,7 @@ fi

# Bazel test only builds targets that are dependencies of a test suite so do a full build first.
$bazel build //... \
--build_tag_filters "$tag_filter" \
--build_tag_filters "${tag_filter:1}" \
--profile build-profile.json \
--experimental_profile_include_target_label \
--build_event_json_file build-events.json \
Expand Down Expand Up @@ -75,8 +80,8 @@ start_postgresql

# Run the tests.
$bazel test //... \
--build_tag_filters "$tag_filter" \
--test_tag_filters "$tag_filter" \
--build_tag_filters "${tag_filter:1}" \
--test_tag_filters "${tag_filter:1}" \
--test_env "POSTGRESQL_HOST=${POSTGRESQL_HOST}" \
--test_env "POSTGRESQL_PORT=${POSTGRESQL_PORT}" \
--test_env "POSTGRESQL_USERNAME=${POSTGRESQL_USERNAME}" \
Expand Down
2 changes: 2 additions & 0 deletions ci/cron/daily-compat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,8 @@ jobs:
bad_file=daml-lf/integration-test-lib/src/main/com/daml/lf/CantonFixture.scala
sed -i 's|"external/canton/lib/.*|"'$canton_local_path'"|' $bad_file
sed -i 's|SKIP_DEV_CANTON_TESTS=.*|SKIP_DEV_CANTON_TESTS=false|' build.sh
sed -i 's|skip_dev_canton = .*|skip_dev_canton = "False"|' build.ps1
sed -e 's/^/# /' COPY > canton_dep.bzl
cat <<EOF >> canton_dep.bzl
Expand Down

0 comments on commit 1f3c22c

Please sign in to comment.