daml/ledger/test-common/BUILD.bazel

85 lines
2.2 KiB
Python
Raw Normal View History

# Copyright (c) 2021 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
load(
"//rules_daml:daml.bzl",
"daml_compile",
)
load(
"//bazel_tools:scala.bzl",
"da_scala_library",
)
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
load(
"//language-support/scala/codegen:codegen.bzl",
"dar_to_scala",
)
load(
"//daml-lf/language:daml-lf.bzl",
"lf_stable_version",
)
da_scala_library(
name = "test-common",
srcs = glob(["src/main/scala/**/*.scala"]),
visibility = [
"//visibility:public",
],
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
deps = [
"//ledger-api/grpc-definitions:ledger_api_proto_scala",
Ledger API: Add healthcheck endpoints. (#3573) * grpc-definitions: Delete health_service.proto We can use the version in io.grpc:grpc-services instead. * ledger: Delete ledger/API.md. * sandbox: Fix warnings in ApiServices flagged by IntelliJ. * sandbox: Implement a dummy grpc.health.v1.Health.Check endpoint. * sandbox: Implement a dummy grpc.health.v1.Health.Watch endpoint. * sandbox: Drop repeated elements from grpc.health.v1.Health.Watch. * sandbox: Wrap the HealthService in basic tests. * sandbox: Stop streaming the server health too. * ledger-api-test-tool: Health check tests. * Add a changelog entry for the health check endpoints. CHANGELOG_BEGIN - [Ledger API] Add healthcheck endpoints, conforming to the `GRPC Health Checking Protocol <https://github.com/grpc/grpc/blob/master/doc/health-checking.md>`_. It is always ``SERVING`` for now. - [DAML Ledger Integration Kit] Add conformance test coverage for the ``grpc.health.v1.Health`` service. CHANGELOG_END * ledger-api-integration-tests: Increment the number of services. * Apply suggestions from code review Co-Authored-By: Stefano Baghino <43749967+stefanobaghino-da@users.noreply.github.com> * sandbox: Use `AkkaBeforeAndAfterAll` in the HealthServiceSpec. In an attempt to get it working on CI. * sandbox: Change `dropRepeated` to `DropRepeated()`. Keep it in one file. * test-common: Use `Delayed.by` in `TimeBoundObserver`. * test-common: Close the source when `TimeBoundObserver` completes. * ./fmt.sh That'll teach me not to `--no-verify` just because it's a merge commit. * sandbox: Inline `HealthService.suppress`. At some point it was being used twice. * sandbox: Increase the timeout for HealthServiceSpec. * sandbox: Reimplement HealthService using the Scala protobuf types. * sandbox: Generate an Akka-compatible trait for the health service. And refactor a lot of test code to make it easy to test. * ledger-api-common: Move the HealthService here. * rs-grpc-testing-utils: Publish to Maven. * rs-grpc-testing-utils: Add Maven coordinates.
2019-11-22 17:02:05 +03:00
"//libs-scala/timer-utils",
Replace NamedLoggerFactory (#4097) * Replace NamedLoggerFactory CHANGELOG_BEGIN CHANGELOG_END * Recover change lost in rebase * Address https://github.com/digital-asset/daml/pull/4045#discussion_r366883577 * Address https://github.com/digital-asset/daml/pull/4045#discussion_r366885112 * Address two open review comments Address https://github.com/digital-asset/daml/pull/4045#discussion_r366885448 Address https://github.com/digital-asset/daml/pull/4045#discussion_r366885981 * Address outstanding compilation errors * Replace mocking with in-memory log collector * Address https://github.com/digital-asset/daml/pull/4097#pullrequestreview-344639319 * Address https://github.com/digital-asset/daml/pull/4045#discussion_r366886250 The generation of code to have logging in the services has been replaced by helpers classes. This will allow to enrich the context received at construction by the service implementations. * Use ContextualizedLogger for TrackerMap * Remove deleted logging packages from artifacts.yaml * Remove remaining deleted artifact from artifacts.yaml * Address https://github.com/digital-asset/daml/pull/4097#discussion_r368640231 * Address https://github.com/digital-asset/daml/pull/4097#discussion_r368648027 * Address https://github.com/digital-asset/daml/pull/4097#discussion_r368652178 * Address https://github.com/digital-asset/daml/pull/4097#discussion_r368654996 * Annotate type of references to logErrorOnCall * Address https://github.com/digital-asset/daml/pull/4097#discussion_r368869575
2020-01-21 12:57:28 +03:00
"@maven//:ch_qos_logback_logback_classic",
"@maven//:ch_qos_logback_logback_core",
"@maven//:io_grpc_grpc_context",
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
],
)
[
[
daml_compile(
name = "%s-tests" % test_name,
srcs = glob(["src/main/daml/%s/*.daml" % test_name]),
target = target,
visibility = ["//visibility:public"],
),
dar_to_scala(
name = "%s-tests.scala-codegen" % test_name,
srcs = [":%s-tests.dar" % test_name],
package_prefix = "com.daml.ledger.test.%s" % test_name,
srcjar_out = "%s.scala.srcjar" % test_name,
verbosity = 2,
visibility = ["//visibility:public"],
),
da_scala_library(
name = "%s-tests.scala" % test_name,
srcs = [":%s-tests.scala-codegen" % test_name],
visibility = ["//visibility:public"],
deps = [
"//language-support/scala/bindings",
] + extra_deps,
),
]
for (test_name, target, extra_deps) in [
(
"model",
lf_stable_version,
["@maven//:org_scala_lang_modules_scala_collection_compat_2_12"],
),
(
"semantic",
lf_stable_version,
["@maven//:org_scala_lang_modules_scala_collection_compat_2_12"],
),
("performance", lf_stable_version, []),
]
]
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
filegroup(
name = "dar-files",
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
srcs = [
":model-tests.dar",
":performance-tests.dar",
":semantic-tests.dar",
New Ledger API test tool (#2282) * New acceptance test tool prototype * Fix transaction filter helper * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308081386 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r308082432 Moreover, creates specific helpers for test DAML code. * Move helpers from session to context Remove a circular dependency between session and context, and limits the usage of implicits. * Run tests with ledgers out of process * Prepare for drop in * Temporary timeout increase * Move bulk of the logic to the test runner * Have a map of tests for CLI integration * Timeout per-test, runner uses context, renaming * Allow usage of time service, integrate semantic tests * Integrate CLI SSL configuration * Integrate failure expectation CLI option * Integrate with failure output verbosity CLI option * Integrate with test listing and picking CLI options * Integrate with timeout scaling CLI option * Integrate with command TTL CLI option * Review CODEOWNERS * Drop previously unimplemented CLI parameters * Expand test todo list to encompass latest additions * Deduplicate some testing infrastructure, swap in new test tool * Remove unused rule * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311045444 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311051974 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311035287 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311055290 * WIP * Make gRPC thread factory spawn non-deamon threads * Remove debug prints, complete divulgence test (missing assertion messages) * Try to detect assertion failure line number * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Add Sandbox binary that starts an ephemeral postgres instance This allows us to use the client_server_test bazel macro to run against the sandbox backed by postgres. Fixes #1543 * Address https://github.com/digital-asset/daml/pull/2282#discussion_r311400695 * Remove TlsConfiguration duplicate, move original to commons * Make assertion more readable Co-Authored-By: Gerolf Seitz <gerolf.seitz@digitalasset.com> * Fix build errors introduced in previous commit - exclude time service tests from reference-v2 - add copyright header to TlsConfiguration * Complete divulgence test and address review comments Restores comments from original divulgence tests and strives to be as close to them as possible. - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311429169 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431156 - Address https://github.com/digital-asset/daml/pull/2282#discussion_r311431913 * Delete old divulgence tests * Restore methods to fetch contracts by template identifier * Run conformance tests on in-memory sandbox * Run conformance tests on the persistent sandbox * Remove workflow identifier workaround * New contract keys test (#2452) * Set channel type for LedgerSession * Add ContractKeysIT * Run tests against reference-server v2 * Removed the old ContractKeysIT. However, ... ... I cannot remove ContractKeysChecks completely, because we have another test path for DARs created prior to DAML-LF 1.6, which doesn't have the submitter == maintainer restriction for contract keys. * Use codegen instead of custom code * Add missing copyright headers * Drop sandbox conformance test suite (seems to not work on Windows CI) * Make time simpler * Test tool tests to run only semantic tests * Make CI behave more consistently * Add missing files to run tests on Postrgres * Fix flaky divulgence test, introduce readable identifiers * Increase sandbox conformance tests timeout * Address https://github.com/digital-asset/daml/pull/2282#discussion_r312363246 * Reintroduce test resource extraction * Read semantic tests from the classpath rather than Bazel * Use codegen types for ContractKeys integration test allocateParty returns Primitive.Party and create and exercise also accept Primitive.Party. This way we don't have to keep a String and Primitive.Party representation around. * Bump timeout for sandbox conformance tests * Remove dependency on Bazel runfiles
2019-08-09 18:00:37 +03:00
],
visibility = ["//visibility:public"],
)