Merge branch 'stable-3.1'
* stable-3.1:
e2e-tests: Rename 'default' after GerritSimulation core change Id33ada17
e2e-tests: Rename 'unique' after GerritSimulation core change I229976f5
e2e-tests: Rename 'name' after GerritSimulation core change I3527fb39
e2e-tests: Remove unnecessary type specification
Change-Id: I1ee60f5eb888bfcba235cd5628133ba13af2b148
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CheckProjectStatisticsUpToGc.scala b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CheckProjectStatisticsUpToGc.scala
index 2487a85..b4b73ec 100644
--- a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CheckProjectStatisticsUpToGc.scala
+++ b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CheckProjectStatisticsUpToGc.scala
@@ -29,14 +29,14 @@
override def relativeRuntimeWeight: Int = MaxSecondsForGcToComplete / SecondsPerWeightUnit
- def this(default: String) {
+ def this(projectName: String) {
this()
- this.default = default
+ this.projectName = projectName
}
- val test: ScenarioBuilder = scenario(unique)
+ val test: ScenarioBuilder = scenario(uniqueName)
.feed(data)
- .exec(http(unique).get("${url}")
+ .exec(http(uniqueName).get("${url}")
.check(regex("\"number_of_loose_objects\": (\\d+),")
.is("0")))
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGc.scala b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGc.scala
index 014e17f..bc74935 100644
--- a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGc.scala
+++ b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGc.scala
@@ -40,13 +40,13 @@
override def relativeRuntimeWeight: Int = maxSecondsToEnqueueGc / SecondsPerWeightUnit
- def this(default: String, deleteChanges: DeleteChangesAfterGc) {
+ def this(projectName: String, deleteChanges: DeleteChangesAfterGc) {
this()
- this.default = default
+ this.projectName = projectName
this.deleteChanges = deleteChanges
}
- val test: ScenarioBuilder = scenario(unique)
+ val test: ScenarioBuilder = scenario(uniqueName)
.feed(data)
.exec(httpRequest
.body(ElFileBody(body)).asJson
@@ -56,7 +56,7 @@
session
})
- private val checkStatsUpToGc = new CheckProjectStatisticsUpToGc(default)
+ private val checkStatsUpToGc = new CheckProjectStatisticsUpToGc(projectName)
private var deleteChanges = new DeleteChangesAfterGc
setUp(
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGcWithProject.scala b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGcWithProject.scala
index d248703..7c1b201 100644
--- a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGcWithProject.scala
+++ b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/CreateChangesTriggeringGcWithProject.scala
@@ -20,13 +20,13 @@
import scala.concurrent.duration._
class CreateChangesTriggeringGcWithProject extends GerritSimulation {
- private val default: String = name
+ private val projectName = className
- private val createProject = new CreateProject(default)
+ private val createProject = new CreateProject(projectName)
private val deleteChanges = new DeleteChangesAfterGc
- private val createChanges = new CreateChangesTriggeringGc(default, deleteChanges)
- private val checkStatsUpToGc = new CheckProjectStatisticsUpToGc(default)
- private val deleteProject = new DeleteProject(default)
+ private val createChanges = new CreateChangesTriggeringGc(projectName, deleteChanges)
+ private val checkStatsUpToGc = new CheckProjectStatisticsUpToGc(projectName)
+ private val deleteProject = new DeleteProject(projectName)
setUp(
createProject.test.inject(
diff --git a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/DeleteChangesAfterGc.scala b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/DeleteChangesAfterGc.scala
index d72f635..4775551 100644
--- a/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/DeleteChangesAfterGc.scala
+++ b/src/test/scala/com/ericsson/gerrit/plugins/gcconductor/scenarios/DeleteChangesAfterGc.scala
@@ -31,12 +31,12 @@
override def relativeRuntimeWeight: Int = (secondsToDeleted + SecondsPerWeightUnit) / SecondsPerWeightUnit
- val test: ScenarioBuilder = scenario(unique)
+ val test: ScenarioBuilder = scenario(uniqueName)
.feed(data)
.exec(session => {
val numbered: Session = session.set(numberKey, upToNumber)
upToNumber -= 1
numbered
})
- .exec(http(unique).delete("${url}${" + numberKey + "}"))
+ .exec(http(uniqueName).delete("${url}${" + numberKey + "}"))
}