Skip to content

Commit

Permalink
Fix nocontenthere URL in other SDKs
Browse files Browse the repository at this point in the history
  • Loading branch information
Philip Stadermann committed Nov 4, 2024
1 parent 8166514 commit 1dff12d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions dotnet/Vaas/test/Vaas.Test/IntegrationTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,10 @@ public async Task ForUrl_WithUrlWithStatusCode4xx_ThrowsVaasClientException()
{
var vaas = await AuthenticateWithCredentials();
var e = await Assert.ThrowsAsync<VaasClientException>(() =>
vaas.ForUrlAsync(new Uri("https://upload.production.vaas.gdatasecurity.de/nocontenthere"),
vaas.ForUrlAsync(new Uri("https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere"),
CancellationToken.None));
Assert.Equal(
"Call failed with status code 404 (Not Found): GET https://upload.production.vaas.gdatasecurity.de/nocontenthere",
"Call failed with status code 404 (Not Found): GET https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere",
e.Message);
}

Expand Down
4 changes: 2 additions & 2 deletions php/tests/vaas/VaasTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -513,10 +513,10 @@ public function testForUrl_WithStatus4xx_ThrowsVaasClientException()
{
$vaas = $this->_getVaas();
$this->expectException(VaasClientException::class);
$this->expectExceptionMessage("Call failed with status code 404 (Not Found): GET https://upload.production.vaas.gdatasecurity.de/nocontenthere");
$this->expectExceptionMessage("Call failed with status code 404 (Not Found): GET https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere");
$vaas->Connect($this->getClientCredentialsGrantAuthenticator()->getToken());

$invalidUrl = "https://upload.production.vaas.gdatasecurity.de/nocontenthere";
$invalidUrl = "https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere";
$verdict = $vaas->ForUrl($invalidUrl);
$this->_getDebugLogger()->info("Verdict for URL " . $invalidUrl . " is " . $verdict->Verdict);
}
Expand Down
6 changes: 3 additions & 3 deletions python/tests/test_vaas.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,9 @@ async def test_for_url_without_cache_returns_clean_for_robots_txt(self):
async def test_for_url__with_url_with_status_code_4xx__raises_VaasClientError(self):
options = get_disabled_options()
async with await create_and_connect(options=options) as vaas:
with self.assertRaises(VaasClientError, msg="Call failed with status code 404 (Not Found): GET https://upload.production.vaas.gdatasecurity.de/nocontenthere") as error:
await vaas.for_url("https://upload.production.vaas.gdatasecurity.de/nocontenthere")
self.assertEqual(str(error.msg), "Call failed with status code 404 (Not Found): GET https://upload.production.vaas.gdatasecurity.de/nocontenthere")
with self.assertRaises(VaasClientError, msg="Call failed with status code 404 (Not Found): GET https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere") as error:
await vaas.for_url("https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere")
self.assertEqual(str(error.msg), "Call failed with status code 404 (Not Found): GET https://gateway.production.vaas.gdatasecurity.de/swagger/nocontenthere")

async def test_for_buffer_traces(self):
tracing = VaasTracing()
Expand Down

0 comments on commit 1dff12d

Please sign in to comment.