nebius/SWE-rebench-V2-PRs huggingface dataset:
Repository: smithy-lang/smithy
Pull request #1940 (2023-08-22 02:57:38)

Add the metadata key to RemovedMetadata event id, eg. `RemovedMetadat…
…a.suppressions`

*Description of changes:*
Adds the metadata key being removed as a diff event subpart: `RemovedMetadata.XXXXXXX`

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.



Patch:
diff --git a/.github/workflows/stale-issues.yml b/.github/workflows/stale-issues.yml
index b0be3a64e..fad299a33 100644
--- a/.github/workflows/stale-issues.yml
+++ b/.github/workflows/stale-issues.yml
@@ -41,4 +41,3 @@ jobs:
 
           repo-token: ${{ secrets.GITHUB_TOKEN }}
           loglevel: DEBUG
-          dryrun: true
diff --git a/smithy-diff/src/main/java/software/amazon/smithy/diff/evaluators/RemovedMetadata.java b/smithy-diff/src/main/java/software/amazon/smithy/diff/evaluators/RemovedMetadata.java
index 27a6e03c2..6bd365f14 100644
--- a/smithy-diff/src/main/java/software/amazon/smithy/diff/evaluators/RemovedMetadata.java
+++ b/smithy-diff/src/main/java/software/amazon/smithy/diff/evaluators/RemovedMetadata.java
@@ -30,7 +30,7 @@ public final class RemovedMetadata extends AbstractDiffEvaluator {
     public List<ValidationEvent> evaluate(Differences differences) {
         return differences.removedMetadata()
                 .map(metadata -> ValidationEvent.builder()
-                        .id(getEventId())
+                        .id(getEventId() + "." + metadata.getLeft())
                         .severity(Severity.DANGER)
                         .sourceLocation(metadata.getRight().getSourceLocation())
                         .message(String.format(


Test patch:
diff --git a/smithy-diff/src/test/java/software/amazon/smithy/diff/evaluators/RemovedMetadataTest.java b/smithy-diff/src/test/java/software/amazon/smithy/diff/evaluators/RemovedMetadataTest.java
index 2ad1649bd..c0c63be50 100644
--- a/smithy-diff/src/test/java/software/amazon/smithy/diff/evaluators/RemovedMetadataTest.java
+++ b/smithy-diff/src/test/java/software/amazon/smithy/diff/evaluators/RemovedMetadataTest.java
@@ -32,6 +32,6 @@ public class RemovedMetadataTest {
         Model modelB = Model.assembler().assemble().unwrap();
         List<ValidationEvent> events = ModelDiff.compare(modelA, modelB);
 
-        assertThat(TestHelper.findEvents(events, "RemovedMetadata").size(), equalTo(1));
+        assertThat(TestHelper.findEvents(events, "RemovedMetadata.foo").size(), equalTo(1));
     }
 }
Repository: smithy-lang/smithy
Pull request #1950 (2023-08-25 14:52:50)

Add short --aut for --allow-unknown-traits
`--allow-unknown-traits` bugs me every time I use it, so I added `--aut` as a short alias.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.



Patch:
diff --git a/smithy-cli/src/main/java/software/amazon/smithy/cli/commands/BuildOptions.java b/smithy-cli/src/main/java/software/amazon/smithy/cli/commands/BuildOptions.java
index 35f88ec9c..06113dafe 100644
--- a/smithy-cli/src/main/java/software/amazon/smithy/cli/commands/BuildOptions.java
+++ b/smithy-cli/src/main/java/software/amazon/smithy/cli/commands/BuildOptions.java
@@ -29,6 +29,7 @@ import software.amazon.smithy.cli.HelpPrinter;
 final class BuildOptions implements ArgumentReceiver {
 
     static final String ALLOW_UNKNOWN_TRAITS = "--allow-unknown-traits";
+    static final String ALLOW_UNKNOWN_TRAITS_SHORT = "--aut";
     static final String MODELS = "<MODELS>";
 
     private boolean allowUnknownTraits;
@@ -37,7 +38,8 @@ final class BuildOptions implements ArgumentReceiver {
 
     @Override
     public void registerHelp(HelpPrinter printer) {
-        printer.option(ALLOW_UNKNOWN_TRAITS, null, "Ignore unknown traits when validating models.");
+        printer.option(ALLOW_UNKNOWN_TRAITS, ALLOW_UNKNOWN_TRAITS_SHORT,
+                       "Ignore unknown traits when validating models.");
         printer.param("--output", null, "OUTPUT_PATH",
                       "Where to write Smithy artifacts, caches, and other files (defaults to './build/smithy').");
 
@@ -48,7 +50,7 @@ final class BuildOptions implements ArgumentReceiver {
 
     @Override
     public boolean testOption(String name) {
-        if (ALLOW_UNKNOWN_TRAITS.equals(name)) {
+        if (ALLOW_UNKNOWN_TRAITS.equals(name) || ALLOW_UNKNOWN_TRAITS_SHORT.equalsIgnoreCase(name)) {
             allowUnknownTraits = true;
             return true;
         }


Test patch:
diff --git a/smithy-cli/src/test/java/software/amazon/smithy/cli/commands/BuildCommandTest.java b/smithy-cli/src/test/java/software/amazon/smithy/cli/commands/BuildCommandTest.java
index 87214e289..711cde8a7 100644
--- a/smithy-cli/src/test/java/software/amazon/smithy/cli/commands/BuildCommandTest.java
+++ b/smithy-cli/src/test/java/software/amazon/smithy/cli/commands/BuildCommandTest.java
@@ -104,6 +104,14 @@ public class BuildCommandTest {
         assertThat(result.stderr(), containsString("Smithy built "));
     }
 
+    @Test
+    public void projectionUnknownTraitsAreAllowedWithShortFlag() throws Exception {
+        String config = Paths.get(getClass().getResource("projection-model-import.json").toURI()).toString();
+        CliUtils.Result result = CliUtils.runSmithy("build", "--aut",  "--config", config);
+
+        assertThat(result.code(), equalTo(0));
+    }
+
     @Test
     public void exceptionsThrownByProjectionsAreDetected() {
         // TODO: need to make a plugin throw an exception
Repository: smithy-lang/smithy
Pull request #2028 (2023-11-06 14:34:30)

Fix null pointer exception in PluginContext.toBuilder



By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.



Patch:
diff --git a/smithy-build/src/main/java/software/amazon/smithy/build/PluginContext.java b/smithy-build/src/main/java/software/amazon/smithy/build/PluginContext.java
index a416f7c7c..f2408bd58 100644
--- a/smithy-build/src/main/java/software/amazon/smithy/build/PluginContext.java
+++ b/smithy-build/src/main/java/software/amazon/smithy/build/PluginContext.java
@@ -254,16 +254,17 @@ public final class PluginContext implements ToSmithyBuilder<PluginContext> {
 
     @Override
     public Builder toBuilder() {
-        return builder()
-                .projection(projectionName, projection)
+        Builder builder =  builder()
                 .model(model)
-                .originalModel(originalModel)
                 .events(events)
                 .settings(settings)
                 .fileManifest(fileManifest)
                 .pluginClassLoader(pluginClassLoader)
                 .sources(sources)
                 .artifactName(artifactName);
+        getProjection().ifPresent(config -> builder.projection(projectionName, config));
+        getOriginalModel().ifPresent(builder::originalModel);
+        return builder;
     }
 
     /**


Test patch:
diff --git a/smithy-build/src/test/java/software/amazon/smithy/build/PluginContextTest.java b/smithy-build/src/test/java/software/amazon/smithy/build/PluginContextTest.java
index aa26b499e..f70e7724b 100644
--- a/smithy-build/src/test/java/software/amazon/smithy/build/PluginContextTest.java
+++ b/smithy-build/src/test/java/software/amazon/smithy/build/PluginContextTest.java
@@ -82,4 +82,16 @@ public class PluginContextTest {
         assertThat(context.getSources(), equalTo(context2.getSources()));
         assertThat(context.getEvents(), equalTo(context2.getEvents()));
     }
+
+    @Test
+    public void roundTripsDefaults() {
+        PluginContext before = PluginContext.builder()
+                .model(Model.builder().build())
+                .fileManifest(new MockManifest())
+                .build();
+        PluginContext after = before.toBuilder().build();
+        assertThat(before.getModel(), equalTo(after.getModel()));
+        assertThat(before.getFileManifest(), equalTo(after.getFileManifest()));
+        assertThat(before.getProjectionName(), equalTo(after.getProjectionName()));
+    }
 }
Repository: smithy-lang/smithy
Pull request #2041 (2023-11-16 14:39:05)

Fix recommended trait provider
This fixes the trait provider for the recommended trait, which was discarding the `reason` by accidentally creating a new builder after it was set.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.



Patch:
diff --git a/smithy-model/src/main/java/software/amazon/smithy/model/traits/RecommendedTrait.java b/smithy-model/src/main/java/software/amazon/smithy/model/traits/RecommendedTrait.java
index ebb63d31d..18bab31ed 100644
--- a/smithy-model/src/main/java/software/amazon/smithy/model/traits/RecommendedTrait.java
+++ b/smithy-model/src/main/java/software/amazon/smithy/model/traits/RecommendedTrait.java
@@ -86,7 +86,7 @@ public final class RecommendedTrait extends AbstractTrait implements ToSmithyBui
         public RecommendedTrait createTrait(ShapeId target, Node value) {
             Builder builder = builder().sourceLocation(value.getSourceLocation());
             value.expectObjectNode().getStringMember("reason", builder::reason);
-            RecommendedTrait result = builder().build();
+            RecommendedTrait result = builder.build();
             result.setNodeCache(value);
             return result;
         }


Test patch:
diff --git a/smithy-model/src/test/java/software/amazon/smithy/model/traits/RecommendedTraitTest.java b/smithy-model/src/test/java/software/amazon/smithy/model/traits/RecommendedTraitTest.java
new file mode 100644
index 000000000..fe84627bc
--- /dev/null
+++ b/smithy-model/src/test/java/software/amazon/smithy/model/traits/RecommendedTraitTest.java
@@ -0,0 +1,22 @@
+package software.amazon.smithy.model.traits;
+
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+
+import org.junit.jupiter.api.Test;
+import software.amazon.smithy.model.node.Node;
+import software.amazon.smithy.model.node.ObjectNode;
+import software.amazon.smithy.model.shapes.ShapeId;
+import software.amazon.smithy.model.traits.RecommendedTrait.Provider;
+
+public class RecommendedTraitTest {
+    @Test
+    public void providerProperlySetsReason() {
+        String reason = "just because";
+        ObjectNode node = Node.objectNode().withMember("reason", reason);
+        Provider provider = new Provider();
+        RecommendedTrait result = provider.createTrait(ShapeId.from("ns.example#Foo$bar"), node);
+        assertTrue(result.getReason().isPresent());
+        assertEquals(result.getReason().get(), reason);
+    }
+}
Repository: smithy-lang/smithy
Pull request #2043 (2023-11-16 18:51:57)

Relax the service name validation to allow one char names
*Issue #, if available:*

*Description of changes:*

Relax the service name validation to allow service names with just one character.


Patch:
diff --git a/smithy-aws-traits/src/main/java/software/amazon/smithy/aws/traits/SdkServiceIdValidator.java b/smithy-aws-traits/src/main/java/software/amazon/smithy/aws/traits/SdkServiceIdValidator.java
index 2e7101a52..9c97c30a4 100644
--- a/smithy-aws-traits/src/main/java/software/amazon/smithy/aws/traits/SdkServiceIdValidator.java
+++ b/smithy-aws-traits/src/main/java/software/amazon/smithy/aws/traits/SdkServiceIdValidator.java
@@ -114,8 +114,8 @@ public final class SdkServiceIdValidator extends AbstractValidator {
             messages.add(String.format("Must not case-insensitively end with `%s`", suffix));
         });
 
-        if (serviceId.length() < 2 || serviceId.length() > 50) {
-            messages.add("Must be between 2 and 50 characters long.");
+        if (serviceId.isEmpty() || serviceId.length() > 50) {
+            messages.add("Must be between 1 and 50 characters long.");
         }
 
         if (!messages.isEmpty()) {


Test patch:
diff --git a/smithy-aws-traits/src/test/java/software/amazon/smithy/aws/traits/SdkServiceIdValidatorTest.java b/smithy-aws-traits/src/test/java/software/amazon/smithy/aws/traits/SdkServiceIdValidatorTest.java
index 0321c121c..1b6fa2227 100644
--- a/smithy-aws-traits/src/test/java/software/amazon/smithy/aws/traits/SdkServiceIdValidatorTest.java
+++ b/smithy-aws-traits/src/test/java/software/amazon/smithy/aws/traits/SdkServiceIdValidatorTest.java
@@ -76,9 +76,9 @@ public class SdkServiceIdValidatorTest {
     @Test
     public void doesNotAllowShortIds() {
         IllegalArgumentException thrown = Assertions.assertThrows(IllegalArgumentException.class, () ->
-                SdkServiceIdValidator.validateServiceId("F"));
+                SdkServiceIdValidator.validateServiceId(""));
 
-        assertThat(thrown.getMessage(), containsString("2 and 50"));
+        assertThat(thrown.getMessage(), containsString("1 and 50"));
     }
 
     @Test
@@ -86,6 +86,6 @@ public class SdkServiceIdValidatorTest {
         IllegalArgumentException thrown = Assertions.assertThrows(IllegalArgumentException.class, () ->
                 SdkServiceIdValidator.validateServiceId("Foobarbazqux Foobarbazqux Foobarbazqux Foobarbazqux"));
 
-        assertThat(thrown.getMessage(), containsString("2 and 50"));
+        assertThat(thrown.getMessage(), containsString("1 and 50"));
     }
 }
Repository: decentralized-identity/did-jwt
Pull request #262 (2022-12-08 18:31:40)

add support for SIOP request JWT
According to JWT Presentation Profile, the SIOP Request JWT does not contain an `iss` claim, it must have a `client_id` claim instead. See https://identity.foundation/jwt-vc-presentation-profile/#self-issued-op-request-object

<img width="373" alt="image" src="https://user-images.githubusercontent.com/178506/206537637-b68b5ae7-2eaf-4bc8-9ece-c3367e1f0b6b.png">


siacomuzzi: > Looks great!
> 
> Thank you for adding this.

Thank you for your review! Do you have plans to publish a new release that includes this change soon?
mirceanis: > > Looks great!
> > Thank you for adding this.
> 
> Thank you for your review! Do you have plans to publish a new release that includes this change soon?

Of course

Patch:
diff --git a/src/JWT.ts b/src/JWT.ts
index f9cc739..2c6ed6a 100644
--- a/src/JWT.ts
+++ b/src/JWT.ts
@@ -402,10 +402,10 @@ export async function verifyJWT(
       : undefined
     : options.proofPurpose
 
-  let did = ''
+  let did
 
-  if (!payload.iss) {
-    throw new Error(`${JWT_ERROR.INVALID_JWT}: JWT iss is required`)
+  if (!payload.iss && !payload.client_id) {
+    throw new Error(`${JWT_ERROR.INVALID_JWT}: JWT iss or client_id are required`)
   }
 
   if (payload.iss === SELF_ISSUED_V2 || payload.iss === SELF_ISSUED_V2_VC_INTEROP) {
@@ -422,6 +422,13 @@ export async function verifyJWT(
       throw new Error(`${JWT_ERROR.INVALID_JWT}: JWT did is required`)
     }
     did = payload.did
+  } else if (!payload.iss && payload.scope === 'openid' && payload.redirect_uri) {
+    // SIOP Request payload
+    // https://identity.foundation/jwt-vc-presentation-profile/#self-issued-op-request-object
+    if (!payload.client_id) {
+      throw new Error(`${JWT_ERROR.INVALID_JWT}: JWT client_id is required`)
+    }
+    did = payload.client_id
   } else {
     did = payload.iss
   }


Test patch:
diff --git a/src/__tests__/JWT.test.ts b/src/__tests__/JWT.test.ts
index cb36715..00e1f43 100644
--- a/src/__tests__/JWT.test.ts
+++ b/src/__tests__/JWT.test.ts
@@ -1005,11 +1005,11 @@ describe('verifyJWT() for ES256K', () => {
     )
   })
 
-  it('rejects a pregenerated JWT without iss', async () => {
+  it('rejects a pregenerated JWT without iss or client_id', async () => {
     expect.assertions(1)
     const jwt =
       'eyJ0eXAiOiJKV1QiLCJhbGciOiJFUzI1NksifQ.eyJpYXQiOjE0ODUzMjExMzN9.aa3_8ZH99MjFoHTrNjOm7Pgq5VL5A13DHR5MTd_dBw2B_pWgNuz4N1tbrocTP0MgDlRbovKmTTDrGNjNMPqH3g'
-    await expect(verifyJWT(jwt, { resolver })).rejects.toThrowError(/JWT iss is required/)
+    await expect(verifyJWT(jwt, { resolver })).rejects.toThrowError(/JWT iss or client_id are required/)
   })
 
   it('rejects a self-issued v2 JWT without sub', async () => {
Repository: codecov/uploader
Pull request #321 (2021-08-19 18:56:17)

fix: trim git output


Patch:
diff --git a/src/ci_providers/provider_bitbucket.ts b/src/ci_providers/provider_bitbucket.ts
index 161713b..f5c0c34 100644
--- a/src/ci_providers/provider_bitbucket.ts
+++ b/src/ci_providers/provider_bitbucket.ts
@@ -1,4 +1,5 @@
 import childProcess from 'child_process'
+import { runExternalProgram } from '../helpers/util'
 import { validateSHA } from '../helpers/validate'
 import { IServiceParams, UploaderEnvs, UploaderInputs } from '../types'
 
@@ -44,7 +45,7 @@ function _getSHA(inputs: UploaderInputs): string {
   let commit = envs.BITBUCKET_COMMIT || ''
 
   if (commit && validateSHA(commit, 12)) {
-    commit = childProcess.execFileSync('git', ['rev-parse', commit])
+    commit = runExternalProgram('git', ['rev-parse', commit])
   }
 
   return args.sha || commit || ''
diff --git a/src/helpers/util.ts b/src/helpers/util.ts
index 9a30d97..c5087c0 100644
--- a/src/helpers/util.ts
+++ b/src/helpers/util.ts
@@ -12,5 +12,5 @@ export function runExternalProgram(
   if (result.error) {
     throw new Error(`Error running external program: ${result.error}`)
   }
-  return result.stdout.toString().trimRight()
+  return result.stdout.toString().trim()
 }


Test patch:
diff --git a/test/helpers/util.test.ts b/test/helpers/util.test.ts
index 5f92966..b1ac811 100644
--- a/test/helpers/util.test.ts
+++ b/test/helpers/util.test.ts
@@ -31,7 +31,7 @@ describe('runExternalProgram()', () => {
 
     })
 
-    it('should throw an error when program returns an error', () => {
+    it('should return stdout on success', () => {
         const spawnSync = td.replace(childProcess, 'spawnSync')
         td.when(spawnSync('ls', ['-geewhiz'])).thenReturn({
           stdout: 'I am output',
@@ -39,4 +39,19 @@ describe('runExternalProgram()', () => {
         expect(runExternalProgram('ls', ['-geewhiz'])).toEqual("I am output")
 
     })
+
+    it('should return a trimmed string with no newlines', () => {
+        const spawnSync = td.replace(childProcess, 'spawnSync')
+        td.when(spawnSync('ls', ['-geewhiz'])).thenReturn({
+          stdout: `
+          
+          
+          I am output
+          
+          
+          `,
+        })
+        expect(runExternalProgram('ls', ['-geewhiz'])).toEqual("I am output")
+
+    })
 })
\ No newline at end of file
diff --git a/test/providers/provider_bitbucket.test.ts b/test/providers/provider_bitbucket.test.ts
index 085b70b..7d69ae8 100644
--- a/test/providers/provider_bitbucket.test.ts
+++ b/test/providers/provider_bitbucket.test.ts
@@ -158,9 +158,9 @@ describe('Bitbucket Params', () => {
       slug: 'testOwner/testSlug',
     }
 
-    const execFileSync = td.replace(childProcess, 'execFileSync')
+    const execFileSync = td.replace(childProcess, 'spawnSync')
     td.when(execFileSync('git', ['rev-parse', 'testingsha12'])).thenReturn(
-      'newtestsha',
+      { stdout: 'newtestsha'},
     )
     const params = providerBitbucket.getServiceParams(inputs)
     expect(params).toMatchObject(expected)
Repository: codecov/uploader
Pull request #365 (2021-09-16 13:56:14)

Revert 363
Reverts #363 


Patch:
diff --git a/src/helpers/web.ts b/src/helpers/web.ts
index 8131991..f7de0b8 100644
--- a/src/helpers/web.ts
+++ b/src/helpers/web.ts
@@ -114,9 +114,9 @@ export function generateQuery(queryParams: IServiceParams): string {
   if (queryParams.pr === 0  || isNaN(Number(queryParams.pr))) {
     queryParams.pr = ''
   }
-  return new URLSearchParams(Object.entries(queryParams)
-    .map(([key, value]) => [snakeCase(key), value])
-  ).toString()
+  return Object.entries(queryParams)
+    .map(([key, value]) => `${snakeCase(key)}=${value}`)
+    .join('&')
 }
 
 export function parsePOSTResults(uploadURL: string): {


Test patch:
diff --git a/test/helpers/web.test.ts b/test/helpers/web.test.ts
index a3d1b26..72af2bc 100644
--- a/test/helpers/web.test.ts
+++ b/test/helpers/web.test.ts
@@ -89,7 +89,7 @@ describe('Web Helpers', () => {
       job: '6',
     }
     expect(generateQuery(queryParams)).toBe(
-      'branch=testBranch&commit=commitSHA&build=4&build_url=https%3A%2F%2Fci-providor.local%2Fjob%2Fxyz&name=testName&tag=tagV1&slug=testOrg%2FtestRepo&service=testingCI&flags=unit%2Cuploader&pr=2&job=6',
+      'branch=testBranch&commit=commitSHA&build=4&build_url=https://ci-providor.local/job/xyz&name=testName&tag=tagV1&slug=testOrg/testRepo&service=testingCI&flags=unit,uploader&pr=2&job=6',
     )
   })
 
@@ -108,7 +108,7 @@ describe('Web Helpers', () => {
       job: '6',
     }
     expect(generateQuery(queryParams)).toBe(
-      'branch=testBranch&commit=commitSHA&build=4&build_url=https%3A%2F%2Fci-providor.local%2Fjob%2Fxyz&name=testName&tag=tagV1&slug=testOrg%2FtestRepo&service=testingCI&flags=unit%2Cuploader&pr=&job=6',
+      'branch=testBranch&commit=commitSHA&build=4&build_url=https://ci-providor.local/job/xyz&name=testName&tag=tagV1&slug=testOrg/testRepo&service=testingCI&flags=unit,uploader&pr=&job=6',
     )
   })
Repository: codecov/uploader
Pull request #366 (2021-09-16 14:03:41)

Release
- #365 


Patch:
diff --git a/src/helpers/web.ts b/src/helpers/web.ts
index f7de0b8..8131991 100644
--- a/src/helpers/web.ts
+++ b/src/helpers/web.ts
@@ -114,9 +114,9 @@ export function generateQuery(queryParams: IServiceParams): string {
   if (queryParams.pr === 0  || isNaN(Number(queryParams.pr))) {
     queryParams.pr = ''
   }
-  return Object.entries(queryParams)
-    .map(([key, value]) => `${snakeCase(key)}=${value}`)
-    .join('&')
+  return new URLSearchParams(Object.entries(queryParams)
+    .map(([key, value]) => [snakeCase(key), value])
+  ).toString()
 }
 
 export function parsePOSTResults(uploadURL: string): {


Test patch:
diff --git a/test/helpers/web.test.ts b/test/helpers/web.test.ts
index 72af2bc..a3d1b26 100644
--- a/test/helpers/web.test.ts
+++ b/test/helpers/web.test.ts
@@ -89,7 +89,7 @@ describe('Web Helpers', () => {
       job: '6',
     }
     expect(generateQuery(queryParams)).toBe(
-      'branch=testBranch&commit=commitSHA&build=4&build_url=https://ci-providor.local/job/xyz&name=testName&tag=tagV1&slug=testOrg/testRepo&service=testingCI&flags=unit,uploader&pr=2&job=6',
+      'branch=testBranch&commit=commitSHA&build=4&build_url=https%3A%2F%2Fci-providor.local%2Fjob%2Fxyz&name=testName&tag=tagV1&slug=testOrg%2FtestRepo&service=testingCI&flags=unit%2Cuploader&pr=2&job=6',
     )
   })
 
@@ -108,7 +108,7 @@ describe('Web Helpers', () => {
       job: '6',
     }
     expect(generateQuery(queryParams)).toBe(
-      'branch=testBranch&commit=commitSHA&build=4&build_url=https://ci-providor.local/job/xyz&name=testName&tag=tagV1&slug=testOrg/testRepo&service=testingCI&flags=unit,uploader&pr=&job=6',
+      'branch=testBranch&commit=commitSHA&build=4&build_url=https%3A%2F%2Fci-providor.local%2Fjob%2Fxyz&name=testName&tag=tagV1&slug=testOrg%2FtestRepo&service=testingCI&flags=unit%2Cuploader&pr=&job=6',
     )
   })