-
Notifications
You must be signed in to change notification settings - Fork 595
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
Minimize setTimeout delays in tests #137
Conversation
@@ -76,7 +76,7 @@ describe('Connection', function() { | |||
numTokenFetches++; | |||
setTimeout(function() { | |||
cb(null, tokenNeverExpires); | |||
}, 100); | |||
}, 1); |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Could you lint your code? Use |
Should be good to go? |
Can you rebase against master, then squash? I think you've got an extra merge commit tagging along. |
Yeah I screwed up and didn't do this on a separate branch so I'll see what I can do... these are the dark sides of git I don't yet fully understand. |
Wow, first try! Sometimes I amaze myself. How's that look? |
Git: Every time you think you've found your way out, there's another dark alley waiting for you. ™️ 🔦 If it helps, my process is usually: $ git checkout -b feature origin/master
# commit a bunch of work
$ git fetch origin
$ git rebase origin/master
# push to my remote The key part being the rebase, which picks up your changes, syncs up with master, then plops your changes back down on top of them. |
It's perfect! Thanks 👯 |
Minimize setTimeout delays in tests
🤖 I have created a release \*beep\* \*boop\* --- ### [1.4.6](https://www.github.com/googleapis/nodejs-memcache/compare/v1.4.5...v1.4.6) (2021-07-21) ### Bug Fixes * Updating WORKSPACE files to use the newest version of the Typescript generator. ([#136](https://www.github.com/googleapis/nodejs-memcache/issues/136)) ([619f23e](https://www.github.com/googleapis/nodejs-memcache/commit/619f23ec0c25c8e5dd97894ada5f65ae763d2721)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
…andwritten libraries (#137) - [ ] Regenerate this pull request now. PiperOrigin-RevId: 429395631 Source-Link: googleapis/googleapis@84594b3 Source-Link: googleapis/googleapis-gen@ed74f97 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWQ3NGY5NzBmZDgyOTE0ODc0ZTZiMjdiMDQ3NjNjZmE2NmJhZmU5YiJ9
🤖 I have created a release \*beep\* \*boop\* --- ## [2.11.0](https://www.github.com/googleapis/nodejs-dialogflow-cx/compare/v2.10.0...v2.11.0) (2021-06-21) ### Features * **v3beta1:** Support partial response feature ([ee8a24a](https://www.github.com/googleapis/nodejs-dialogflow-cx/commit/ee8a24a1e47cb352198880490f047e2ff3d47152)) * **v3beta1:** support sentiment analysis in bot testing ([#127](https://www.github.com/googleapis/nodejs-dialogflow-cx/issues/127)) ([2c45b2c](https://www.github.com/googleapis/nodejs-dialogflow-cx/commit/2c45b2c4e9662aaef7352f3b3edf58c0bf29779e)) ### Bug Fixes * **v3beta1:** set agent default language code as required ([#134](https://www.github.com/googleapis/nodejs-dialogflow-cx/issues/134)) ([ee8a24a](https://www.github.com/googleapis/nodejs-dialogflow-cx/commit/ee8a24a1e47cb352198880490f047e2ff3d47152)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
* chore(main): release 2.1.1 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
[![WhiteSource Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [sinon](https://sinonjs.org/) ([source](https://togithub.com/sinonjs/sinon)) | [`^13.0.0` -> `^14.0.0`](https://renovatebot.com/diffs/npm/sinon/13.0.2/14.0.0) | [![age](https://badges.renovateapi.com/packages/npm/sinon/14.0.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/npm/sinon/14.0.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/npm/sinon/14.0.0/compatibility-slim/13.0.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/npm/sinon/14.0.0/confidence-slim/13.0.2)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>sinonjs/sinon</summary> ### [`v14.0.0`](https://togithub.com/sinonjs/sinon/blob/HEAD/CHANGES.md#​1400) [Compare Source](https://togithub.com/sinonjs/sinon/compare/v13.0.2...v14.0.0) - [`c2bbd826`](https://togithub.com/sinonjs/sinon/commit/c2bbd82641444eb5b32822489ae40f185afbbf00) Drop node 12 (Morgan Roderick) > And embrace Node 18 > > See https://nodejs.org/en/about/releases/ *Released by Morgan Roderick on 2022-05-07.* </details> --- ### Configuration 📅 **Schedule**: "after 9am and before 3pm" (UTC). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/nodejs-service-management).
See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
samples: pull in latest typeless bot, clean up some comments Source-Link: https://togithub.com/googleapis/synthtool/commit/0a68e568b6911b60bb6fd452eba4848b176031d8 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest@sha256:5b05f26103855c3a15433141389c478d1d3fe088fb5d4e3217c4793f6b3f245e
🤖 I have created a release *beep* *boop* --- ## [2.0.3](https://togithub.com/googleapis/nodejs-org-policy/compare/v2.0.2...v2.0.3) (2022-11-11) ### Bug Fixes * Allow passing gax instance to client constructor ([#126](https://togithub.com/googleapis/nodejs-org-policy/issues/126)) ([c7147d4](https://togithub.com/googleapis/nodejs-org-policy/commit/c7147d40a9ed114ec42997d49c2f5dfcff948aad)) * **deps:** Use google-gax v3.5.2 ([#134](https://togithub.com/googleapis/nodejs-org-policy/issues/134)) ([0f1bfb0](https://togithub.com/googleapis/nodejs-org-policy/commit/0f1bfb0007ade736c2ec91f32ff187c80b2d6761)) * Do not import the whole google-gax from proto JS ([#1553](https://togithub.com/googleapis/nodejs-org-policy/issues/1553)) ([#125](https://togithub.com/googleapis/nodejs-org-policy/issues/125)) ([068b0a5](https://togithub.com/googleapis/nodejs-org-policy/commit/068b0a55fe805cedab9e66f62071c8be56f465ed)) * Preserve default values in x-goog-request-params header ([#128](https://togithub.com/googleapis/nodejs-org-policy/issues/128)) ([3f80014](https://togithub.com/googleapis/nodejs-org-policy/commit/3f80014a3c75311555df6cfde8470ae1f72a686f)) * Regenerated protos JS and TS definitions ([#137](https://togithub.com/googleapis/nodejs-org-policy/issues/137)) ([1606459](https://togithub.com/googleapis/nodejs-org-policy/commit/1606459c847f2ed945dccc8e43d57d273fac7ea9)) * use google-gax v3.3.0 ([068b0a5](https://togithub.com/googleapis/nodejs-org-policy/commit/068b0a55fe805cedab9e66f62071c8be56f465ed)) --- This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please).
* feat: support regapic LRO Use gapic-generator-typescript v2.15.1. PiperOrigin-RevId: 456946341 Source-Link: googleapis/googleapis@88fd18d Source-Link: googleapis/googleapis-gen@accfa37 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiYWNjZmEzNzFmNjY3NDM5MzEzMzM1YzY0MDQyYjA2M2MxYzUzMTAyZSJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
🤖 I have created a release *beep* *boop* --- ## [2.1.0](googleapis/nodejs-managed-identities@v2.0.0...v2.1.0) (2022-06-30) ### Features * support regapic LRO ([#137](googleapis/nodejs-managed-identities#137)) ([ee4fadb](googleapis/nodejs-managed-identities@ee4fadb)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [ ] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/nodejs-retail/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary)
* chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual * chore: assert.deelEqual => assert.deepStrictEqual
Mocha was giving warnings that a few tests were running slowly. In both cases, the reason was that there was a
setTimeout
running a few callbacks under a significant delay. I reduced the time to 1ms and tests still passed so I don't see why the delay was necessary. If the delay is necessary, perhaps these tests should be failing under the new conditions I've set.If someone can shed some light on why the callbacks are called under a
setTimeout
in the first place, that would also help me out.