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

chore(deps-dev): bump sinon from 18.0.0 to 19.0.2 #10536

Merged
merged 2 commits into from
Sep 14, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Sep 13, 2024

Bumps sinon from 18.0.0 to 19.0.2.

Changelog

Sourced from sinon's changelog.

19.0.2

  • 4eb4c4bc Use fix 13.0.2 version of fake-timers to get Date to pass instanceof checks (Carl-Erik Kopseng)
  • a5b03db3 Add links to code that is affected by the breaking changes (Carl-Erik Kopseng)

Released by Carl-Erik Kopseng on 2024-09-13.

19.0.1

  • 037ec2d2 Update migration docs (Carl-Erik Kopseng)

Released by Carl-Erik Kopseng on 2024-09-13.

19.0.0

  • 3534ab4f Bump samsam and nise to latest versions (#2617) (Carl-Erik Kopseng)

    Ensures consistency and less breakage when there are "circular" dependencies.

  • 912c568d upgrade fake timers and others (#2612) (Carl-Erik Kopseng)
    • Upgrade dependencies (includes breaking API in Fake Timers)
    • fake-timers: no longer creating dates using the original Date class, but a subclass (proxy)
  • 9715798e Use newer @mochify/* packages (#2609) (Carl-Erik Kopseng)

    Co-authored-by: Maximilian Antoni [email protected]

Released by Carl-Erik Kopseng on 2024-09-13.

18.0.1

Basically a patch release to update a transitive dependency in Nise.

... (truncated)

Commits

Dependabot compatibility score

You can trigger a rebase of this PR by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [sinon](https://github.com/sinonjs/sinon) from 18.0.0 to 19.0.2.
- [Release notes](https://github.com/sinonjs/sinon/releases)
- [Changelog](https://github.com/sinonjs/sinon/blob/main/docs/changelog.md)
- [Commits](sinonjs/sinon@v18.0.0...v19.0.2)

---
updated-dependencies:
- dependency-name: sinon
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot added dependencies Related to dependency updates javascript Pull requests that update Javascript code labels Sep 13, 2024
@chris48s
Copy link
Member

OK. I haven't worked out what we need to change yet, but I've worked out where the problem is.

The test that breaks is this one

describe('running with metrics enabled', function () {
let server, baseUrl, scope, clock
const metricsPushIntervalSeconds = 1
before('Start the server', async function () {
// Fixes https://github.com/badges/shields/issues/2611
this.timeout(10000)
process.env.INSTANCE_ID = 'test-instance'
server = await createTestServer({
public: {
metrics: {
prometheus: { enabled: true },
influx: {
enabled: true,
url: 'http://localhost:1112/metrics',
instanceIdFrom: 'env-var',
instanceIdEnvVarName: 'INSTANCE_ID',
envLabel: 'localhost-env',
intervalSeconds: metricsPushIntervalSeconds,
},
},
},
private: {
influx_username: 'influx-username',
influx_password: 'influx-password',
},
})
clock = sinon.useFakeTimers()
baseUrl = server.baseUrl
await server.start()
})
after('Shut down the server', async function () {
if (server) {
await server.stop()
}
server = undefined
nock.cleanAll()
delete process.env.INSTANCE_ID
clock.restore()
})
it('should push custom metrics', async function () {
scope = nock('http://localhost:1112', {
reqheaders: {
'Content-Type': 'application/x-www-form-urlencoded',
},
})
.post(
'/metrics',
/prometheus,application=shields,category=static,env=localhost-env,family=static-badge,instance=test-instance,service=static_badge service_requests_total=1\n/,
)
.basicAuth({ user: 'influx-username', pass: 'influx-password' })
.reply(200)
await got(`${baseUrl}badge/fruit-apple-green.svg`)
await clock.tickAsync(1000 * metricsPushIntervalSeconds + 500)
expect(scope.isDone()).to.be.equal(
true,
`pending mocks: ${scope.pendingMocks()}`,
)
})
})

If I comment that out, the rest of the suite passes. The other failures in CI are red herrings. I think they are just a result of never running
clock.restore()
to clean up after that one fails.

I've not worked out how to fix it yet though.

Sinon 19 upgrade notes: https://sinonjs.org/guides/migration-guide#sinon-19

Copy link
Contributor

Messages
📖

✨ Thanks for your contribution to Shields, @dependabot[bot]!

Generated by 🚫 dangerJS against 641d129

@chris48s chris48s added this pull request to the merge queue Sep 14, 2024
Merged via the queue into master with commit 8cd2718 Sep 14, 2024
23 checks passed
@chris48s chris48s deleted the dependabot/npm_and_yarn/sinon-19.0.2 branch September 14, 2024 15:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Related to dependency updates javascript Pull requests that update Javascript code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant