Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(circleci): Allow for quotes around dependencies #29902

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

AugPro
Copy link

@AugPro AugPro commented Jun 27, 2024

Changes

This PR firstly demonstrates a bug when using quotes around circleci dependencies, the version is incorrectly parsed, even though the yaml is valid. 329b342

Looking at the CI run, you'll see that the dependency version is parsed as volatile" instead of volatile.

Summary of all failing tests
FAIL lib/modules/manager/circleci/extract.spec.ts (888 MB heap size)
   modules/manager/circleci/extract  extractPackageFile()  extracts orbs too

    expect(received).toMatchObject(expected)

    - Expected  - 1
    + Received  + 1

    @@ -10,11 +10,11 @@
          "datasource": "orb",
          "depName": "no-version",
          "depType": "orb",
        },
        Object {
    -     "currentValue": "volatile",
    +     "currentValue": "volatile\"",
          "datasource": "orb",
          "depName": "volatile",
          "depType": "orb",
        },
        Object {},

      20 |     it('extracts orbs too', () => {
      21 |       const res = extractPackageFile(file2);
    > 22 |       expect(res?.deps).toMatchObject([
         |                         ^
      23 |         {
      24 |           depName: 'release-workflows',
      25 |           currentValue: '4.1.0',

      at Object.<anonymous> (lib/modules/manager/circleci/extract.spec.ts:22:25)

The goal is to agree on a way to fix this issue, and then fix it.

Context

I did not find any open issue or discussion referencing this bug. I wanted to open one and figured it was simpler to show the bug via the CI and a simple fixture change.

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests but ran on a real repository, or
  • Both unit tests + ran on a real repository

@AugPro AugPro changed the title test: update circleci fixtures with quotes to demonstrate issue fix(circleci): Allow for quotes around dependencies Jun 27, 2024
@AugPro AugPro marked this pull request as ready for review June 27, 2024 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant