Skip to content

Commit

Permalink
Fix test name uniqueness (#8020)
Browse files Browse the repository at this point in the history
  • Loading branch information
PerfectSlayer authored Nov 28, 2024
1 parent 36fb475 commit 4d76fed
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class LocalFSGitInfoExtractorTest extends DDSpecification {
)
}

def "test git info extraction for local fs"() {
def "test git info extraction for local fs #gitFolder"() {
setup:
def sut = new LocalFSGitInfoExtractor()

Expand Down Expand Up @@ -119,7 +119,7 @@ class LocalFSGitInfoExtractorTest extends DDSpecification {
fullMessage == null
}

def "test repository url with different remotes"() {
def "test repository url with different remotes #gitFolder"() {
setup:
def sut = new LocalFSGitInfoExtractor()

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,11 @@ class SerializerTest extends Specification {
this.b = b
}

@Override
String toString() {
"$a / $b"
}

boolean equals(o) {
if (this.is(o)) {
return true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -688,7 +688,7 @@ class PropagationModuleTest extends IastModuleImplTestBase {
}

private Date date(Source source = null, int mark = NOT_MARKED) {
final result = new Date()
final result = new Date(1234567890) // Use a fixed date
if (source != null) {
taintObject(result, source, mark)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import datadog.trace.agent.test.AgentTestRunner
import datadog.trace.agent.test.server.http.TestHttpServer
import datadog.trace.api.iast.InstrumentationBridge
import datadog.trace.api.iast.sink.SsrfModule
import org.apache.http.HttpHost
Expand Down Expand Up @@ -31,7 +32,7 @@ class IastHttpClientInstrumentationTest extends AgentTestRunner {
}
}

void 'test ssrf httpClient execute method with args #args expecting call module'() {
void 'test ssrf httpClient execute method expecting call module #iterationIndex'() {
given:
final ssrf = Mock(SsrfModule)
InstrumentationBridge.registerIastModule(ssrf)
Expand Down Expand Up @@ -68,7 +69,7 @@ class IastHttpClientInstrumentationTest extends AgentTestRunner {
return new BasicHttpRequest("GET", server.address.toString())
}

private static HttpHost getHttpHost(final server){
private static HttpHost getHttpHost(final TestHttpServer server){
return new HttpHost(server.address.host, server.address.port, server.address.scheme)
}
}

0 comments on commit 4d76fed

Please sign in to comment.