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

refactor: update and simplify some dependencies #281

Merged
merged 1 commit into from
Oct 25, 2024

Conversation

dpogue
Copy link
Member

@dpogue dpogue commented Oct 25, 2024

Motivation and Context

Since we can't adopt the latest versions of execa and globby due to ESM, and we use them for very specific purposes here, replace them with built-ins where possible (and use fast-glob where not possible).

Description

  • Replace the single execa call with child_process.spawnSync, since we know that we're invoking git rather than a shell script
  • Replace the one spot that used globby with fast-glob
  • On versions of node with fs.globSync, use that instead of fast-glob
  • Fix a warning in a Jasmine test about done getting called with arguments
  • Update testing dependencies to latest versions

Testing

  • Confirmed that the contents of the cordova.js file are the same before and after these changes (some extra spaces removed, but no code changes)
  • Confirmed that all unit tests run and pass

Checklist

  • I've run the tests to see all new and existing tests pass

Since we can't adopt the latest versions of execa and globby due to ESM,
and we use them for very specific purposes here, replace them with
built-ins where possible (and use fast-glob where not possible).
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 83.62%. Comparing base (d77f379) to head (621c944).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #281   +/-   ##
=======================================
  Coverage   83.62%   83.62%           
=======================================
  Files          14       14           
  Lines         519      519           
=======================================
  Hits          434      434           
  Misses         85       85           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@erisu erisu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code changes LGTM

@dpogue dpogue merged commit 29d7b0a into apache:master Oct 25, 2024
9 checks passed
@dpogue dpogue deleted the cleanups branch October 25, 2024 06:52
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.

3 participants