Skip to content

Commit

Permalink
ledger-api-test-tool: Remove deprecated options. (#12533)
Browse files Browse the repository at this point in the history
CHANGELOG_BEGIN
CHANGELOG_END
  • Loading branch information
SamirTalwar authored Jan 21, 2022
1 parent 5ab9eae commit 3044958
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 32 deletions.
7 changes: 0 additions & 7 deletions ledger/ledger-api-test-tool/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -258,13 +258,6 @@ conformance_test(
"--additional=LotsOfPartiesIT",
"--additional=TransactionScaleIT",
"--additional=TLSOnePointThreeIT",
# Makes sure that deprecated CLI options can still be used to make sure existing CI pipelines are not broken.
# This test should fail if any deprecated CLI option has any effect whatsoever -- they are preserved
# exclusively for backwards-compatibility.
# Deprecated CLI options will be eventually removed.
"--load-scale-factor=THIS_OPTION_IS_DEPRECATED_AND_HAS_NO_EFFECT",
"--target-port=THIS_OPTION_IS_DEPRECATED_AND_HAS_NO_EFFECT",
"--all-tests",
],
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@ object Cli {

private[this] implicit val fileRead: Read[File] = Read.reads(Paths.get(_).toFile)

private def reportUsageOfDeprecatedOption[B](option: String) = { (_: Any, config: B) =>
System.err.println(
s"WARNING: $option has been deprecated and will be removed in a future version"
)
config
}

private def endpointRead: Read[(String, Int)] = new Read[(String, Int)] {
val arity = 2
val reads: String => (String, Int) = { s: String =>
Expand Down Expand Up @@ -69,13 +62,6 @@ object Cli {
.optional()
.text("Number of connection attempts to the participants. Applied to all endpoints.")

// FIXME Make client_server_test more flexible and remove this deprecated option
opt[String]("target-port")
.optional()
.text("DEPRECATED: this option is no longer used and has no effect")
.action(reportUsageOfDeprecatedOption("--target-port"))
.hidden()

opt[File]("pem")
.optional()
.text("TLS: The pem file to be used as the private key. Applied to all endpoints.")
Expand Down Expand Up @@ -110,12 +96,6 @@ object Cli {
|use numbers lower than 1.0 to make test timeouts more strict.""".stripMargin
)

opt[String](name = "load-scale-factor")
.optional()
.text("DEPRECATED: this option is no longer used and has no effect")
.action(reportUsageOfDeprecatedOption("--load-scale-factor"))
.hidden()

opt[Int](name = "concurrent-test-runs")
.optional()
.action((v, c) => c.copy(concurrentTestRuns = v))
Expand Down Expand Up @@ -188,11 +168,6 @@ object Cli {
"The path of the benchmark report file produced by performance tests (default: stdout)."
)

opt[Unit]("all-tests")
.text("DEPRECATED: All tests are always run by default.")
.action(reportUsageOfDeprecatedOption("--all-tests"))
.hidden()

opt[Unit]("shuffle-participants")
.action((_, c) => c.copy(shuffleParticipants = true))
.text(
Expand Down

0 comments on commit 3044958

Please sign in to comment.