diff --git a/.all-contributorsrc b/.all-contributorsrc deleted file mode 100644 index d99c65bf..00000000 --- a/.all-contributorsrc +++ /dev/null @@ -1,66 +0,0 @@ -{ - "projectName": "plugin-ruby", - "projectOwner": "kddeisz", - "repoType": "github", - "repoHost": "https://github.com", - "files": [ - "README.md" - ], - "imageSize": 100, - "commit": true, - "contributors": [ - { - "login": "kddeisz", - "name": "Kevin Deisz", - "avatar_url": "https://avatars2.githubusercontent.com/u/5093358?v=4", - "profile": "https://kevindeisz.com", - "contributions": [ - "code", - "doc", - "maintenance", - "review", - "test" - ] - }, - { - "login": "AlanFoster", - "name": "Alan Foster", - "avatar_url": "https://avatars2.githubusercontent.com/u/1271782?v=4", - "profile": "https://www.alanfoster.me/", - "contributions": [ - "code", - "doc", - "review", - "test" - ] - }, - { - "login": "johnschoeman", - "name": "johnschoeman", - "avatar_url": "https://avatars0.githubusercontent.com/u/16049495?v=4", - "profile": "https://github.com/johnschoeman", - "contributions": [ - "test" - ] - }, - { - "login": "aaronjensen", - "name": "Aaron Jensen", - "avatar_url": "https://avatars3.githubusercontent.com/u/8588?v=4", - "profile": "https://twitter.com/aaronjensen", - "contributions": [ - "doc" - ] - }, - { - "login": "cbothner", - "name": "Cameron Bothner", - "avatar_url": "https://avatars1.githubusercontent.com/u/4642599?v=4", - "profile": "http://cameronbothner.com", - "contributions": [ - "code" - ] - } - ], - "contributorsPerLine": 7 -} diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index 7053dc17..00000000 --- a/.eslintignore +++ /dev/null @@ -1 +0,0 @@ -/coverage/ diff --git a/.eslintrc.json b/.eslintrc.json deleted file mode 100644 index 9ea43902..00000000 --- a/.eslintrc.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "extends": "airbnb-base", - "env": { - "jest": true, - "node": true - }, - "rules": { - "arrow-body-style": ["error", "as-needed"], - "arrow-parens": ["error", "as-needed"], - "comma-dangle": ["error", "never"], - "global-require": "off", - "no-unused-vars": ["error", { - "argsIgnorePattern": "^_", - "varsIgnorePattern": "^_" - }], - "object-curly-newline": "off", - "prefer-spread": "off", - "quotes": ["error", "double"] - }, - "globals": { - "runCase": "readonly" - } -} diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 00000000..901dd01a --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1 @@ +open_collective: prettier-ruby diff --git a/.github/ISSUE_TEMPLATE/formatting.md b/.github/ISSUE_TEMPLATE/formatting.md deleted file mode 100644 index 552b501a..00000000 --- a/.github/ISSUE_TEMPLATE/formatting.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -name: ✨ Formatting -about: Issues for ugly or incorrect code ---- - -## Metadata - -* Ruby version: ... -* @prettier/plugin-ruby version: ... - -## Input - -```ruby -# Code snippet -``` - -## Current output - -```ruby -# Code snippet, or crash details -``` - -## Expected output - -```ruby -# code snippet -``` diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..29fe4b24 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,14 @@ +version: 2 +updates: + - package-ecosystem: "npm" + directory: "/" + schedule: + interval: "daily" + - package-ecosystem: "bundler" + directory: "/" + schedule: + interval: "daily" + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "daily" diff --git a/.github/workflows/auto-merge.yml b/.github/workflows/auto-merge.yml new file mode 100644 index 00000000..44908aae --- /dev/null +++ b/.github/workflows/auto-merge.yml @@ -0,0 +1,22 @@ +name: Dependabot auto-merge +on: pull_request + +permissions: + contents: write + pull-requests: write + +jobs: + dependabot: + runs-on: ubuntu-latest + if: ${{ github.actor == 'dependabot[bot]' }} + steps: + - name: Dependabot metadata + id: metadata + uses: dependabot/fetch-metadata@v2.0.0 + with: + github-token: "${{ secrets.GITHUB_TOKEN }}" + - name: Enable auto-merge for Dependabot PRs + run: gh pr merge --auto --merge "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 00000000..7c247608 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,68 @@ +name: Main +on: + - push + - pull_request + +jobs: + ci: + name: CI + strategy: + fail-fast: false + matrix: + platform: + - macos-latest + - ubuntu-latest + - windows-latest + ruby: + - "3.0" + - "3.1" + - "3.2" + runs-on: ${{ matrix.platform }} + steps: + - uses: actions/checkout@main + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + ruby-version: ${{ matrix.ruby }} + - uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: yarn + - run: yarn install --frozen-lockfile + - run: yarn test + - run: bundle exec rake test + + lint: + name: Lint + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@main + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + ruby-version: "3.0" + - uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: yarn + - run: yarn install --frozen-lockfile + - run: yarn checkFormat + - run: yarn lint + + gem: + name: Gem + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@main + - uses: ruby/setup-ruby@v1 + with: + bundler-cache: true + ruby-version: "3.2" + - uses: actions/setup-node@v4 + with: + node-version: 20.x + cache: yarn + - run: yarn install --frozen-lockfile + - run: gem build -o prettier.gem + - run: gem unpack prettier.gem + - run: prettier/exe/rbprettier --help diff --git a/.gitignore b/.gitignore index c67234bd..1a035cd8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,13 @@ +/.eslintcache /coverage/ /node_modules/ /yarn-error.log /pkg/ +/test.rb +/test.rbs +/test.haml *.gem + +# This is to better support the GitHub actions checking - since bundler changes +# to being shipped by default with Ruby starting on 2.6. +/Gemfile.lock diff --git a/.npmignore b/.npmignore index 8b89b1fa..7a1a86d7 100644 --- a/.npmignore +++ b/.npmignore @@ -1,7 +1,19 @@ +/.github/ +/bin/ /coverage/ /exe/ /node_modules/ /lib/ /pkg/ /test/ +/vendor/ +/*.gem + +/.* +/Gemfile* +/Rakefile +/prettier-*.gem /yarn-error.log +/test.rb +/test.rbs +/test.haml diff --git a/.prettierignore b/.prettierignore new file mode 100644 index 00000000..f430e82a --- /dev/null +++ b/.prettierignore @@ -0,0 +1,18 @@ +/.bundle/ +/coverage/ +/pkg/ +/playground/ +/vendor/ + +/.eslintcache +/.*ignore +/bin/port +/docs/logo.png +/*.lock +/LICENSE +/test.rb +/test.rbs +/test.haml + +*.txt +*.gem diff --git a/.rubocop.yml b/.rubocop.yml deleted file mode 100644 index 3a1021e8..00000000 --- a/.rubocop.yml +++ /dev/null @@ -1,7 +0,0 @@ -AllCops: - DisplayCopNames: true - DisplayStyleGuide: true - TargetRubyVersion: 2.6 - -Style/Documentation: - Enabled: false diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 7e6d47bd..00000000 --- a/.travis.yml +++ /dev/null @@ -1,18 +0,0 @@ -language: ruby -rvm: -- ruby-head -- 2.6.1 -- 2.5.3 -branches: - only: master -before_install: bin/ci-install -script: -- yarn test -- yarn lint -- yarn build -- gem build prettier.gemspec -- bundle exec rake test -- bundle exec rbprettier --check 'src/ripper.rb' 'lib/**/*.rb' 'test/*_test.rb' 'prettier.gemspec' -cache: -- bundler -- yarn diff --git a/CHANGELOG.md b/CHANGELOG.md index e67b9a96..0e310a26 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,225 +6,1364 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) a ## [Unreleased] +## [4.0.4] - 2023-12-12 + +### Changed + +- [#1413](https://github.com/prettier/plugin-ruby/pull/1413) - hrabe - Fix the cwd detection for mono-repos. + +## [4.0.3] - 2023-11-27 + +### Changed + +- [#1406](https://github.com/prettier/plugin-ruby/pull/1406) - mikesea - Support running without the RBS or Haml plugins loaded. +- [#1407](https://github.com/prettier/plugin-ruby/pull/1407) - hrabe - Support shimmed Ruby versions. + +## [4.0.2] - 2023-07-14 + +### Changed + +- [#1367](https://github.com/prettier/plugin-ruby/pull/1367) - kddnewton - Specify `prettier` as a peer dependency and not a runtime dependency. + +## [4.0.1] - 2023-07-08 + +### Changed + +- [#1363](https://github.com/prettier/plugin-ruby/pull/1363) - mscrivo, kddnewton - Ensure all data is read from socket before attempting to parse to JSON. + +## [4.0.0] - 2023-07-06 + +### Added + +- [#1283](https://github.com/prettier/plugin-ruby/pull/1283) - oriolgual - Use `process.execPath` instead of `"node"`. +- [#1358](https://github.com/prettier/plugin-ruby/pull/1358) - davidalejandroaguilar - Add the `rubyExecutablePath` option. +- [#1359](https://github.com/prettier/plugin-ruby/pull/1359) - kddnewton - Inherit stderr from the parser process in order to provide better error messages when failing to spawn parser server. This will put out missing gem errors, for example. + +### Changed + +- [#1360](https://github.com/prettier/plugin-ruby/pull/1360) - kddnewton - Require prettier v3.0.0+. + +## [3.2.2] - 2022-09-20 + +### Changed + +- [#1276](https://github.com/prettier/plugin-ruby/pull/1276) - kddnewton - Fix the parsing for options being passed to the server process. + +## [3.2.1] - 2022-09-19 + +### Changed + +- [#1274](https://github.com/prettier/plugin-ruby/pull/1274) - kddnewton - Support the next version of `syntax_tree-haml`. + +## [3.2.0] - 2022-07-22 + +### Added + +- [#1250](https://github.com/prettier/plugin-ruby/issues/1250) - alexf101, kddnewton - Respect the `tabWidth` option. + +### Changed + +- [#1255](https://github.com/prettier/plugin-ruby/pull/1255) - soberstadt - The rake task now runs check if write is false. +- [#1237](https://github.com/prettier/plugin-ruby/issues/1237) - boris-petrov - Disable the style rules associated with quotes. +- [#1248](https://github.com/prettier/plugin-ruby/pull/1248) - mhssmnn - Fix process waiting on STDIN. + +## [3.1.2] - 2022-05-13 + +### Changed + +- [#1127](https://github.com/prettier/plugin-ruby/issues/1227) - mscrivo, kddnewton - Support passing the `printWidth` option. + +## [3.1.1] - 2022-05-12 + +### Changed + +- [#1125](https://github.com/prettier/plugin-ruby/pull/1225) - kddnewton - Update the bundled rubocop config to be in sync with Syntax Tree. + +## [3.1.0] - 2022-05-12 + +### Added + +- [#1224](https://github.com/prettier/plugin-ruby/pull/1224) - kddnewton - Support passing the `rubyPlugins` option to configure Syntax Tree. + +## [3.0.0] - 2022-05-04 + +### Added + +- [#1190](https://github.com/prettier/plugin-ruby/pull/1190) - kddnewton - Encoding for source files is now guessed in a much better way. + +### Changed + +- [#1198](https://github.com/prettier/plugin-ruby/issues/1198) - pas-f, kddnewton - Fix crashes on JRuby with do blocks. +- [#1131](https://github.com/prettier/plugin-ruby/issues/1131) - hyrious, kddnewton - Ensure zombie processes are not left around when the server exits. +- [#1206](https://github.com/prettier/plugin-ruby/pull/1206) - kddnewton - Switch back to plain JavaScript for development. +- [#1190](https://github.com/prettier/plugin-ruby/pull/1190) - kddnewton - Switch over to using Syntax Tree for the backend. This now requires that users install the necessary gems. + +### Removed + +- [#1190](https://github.com/prettier/plugin-ruby/pull/1190) - kddnewton - The configuration options have been removed. Instead, configuration is to be done through modifying Syntax Tree. + +## [2.1.0] - 2022-04-04 + +### Added + +- [#1065](https://github.com/prettier/plugin-ruby/issues/1065) - langalex, kddnewton - The ability to set the `PRETTIER_RUBY_TIMEOUT_MS` environment variable to control how long to wait for the parser server to spin up. +- [#1173](https://github.com/prettier/plugin-ruby/pull/1173) - dleavitt - Support for RBS 2.x on Ruby 3.1. + +### Changed + +- [#1028](https://github.com/prettier/plugin-ruby/issues/1028) - levymetal, kddnewton - Fix up some nested formatting with very complicated RSpec assertions. +- [#1035](https://github.com/prettier/plugin-ruby/issues/1035) - qcn, kddnewton - Ensure we don't try to print `return` incorrectly when multiple statements are contained within parentheses. +- [#1048](https://github.com/prettier/plugin-ruby/pull/1048) - kddnewton - Completely refactor the Ruby parser to use classes instead of hashes. Also remove a lot of the `body` keys are replace them with actual names. +- [#1042](https://github.com/prettier/plugin-ruby/issues/1042) - JoshuaKGoldberg, kddnewton - Ensure blocks are printed correctly when there are trailing comments on the `do` keyword. +- [#1134](https://github.com/prettier/plugin-ruby/pull/1134) - mhssmnn - Fix piping for STDIN to the gem process. +- [#1167](https://github.com/prettier/plugin-ruby/pull/1167) - dleavitt - More consistent assignment indentation. +- [#1074](https://github.com/prettier/plugin-ruby/issues/1074) - wagenet, kddnewton - Fix up `return` when nodes return arrays of docs. + +### Removed + +- [#1048](https://github.com/prettier/plugin-ruby/pull/1048) - kddnewton - Drop support for Ruby 2.5. + +## [2.0.0] - 2021-10-28 + +### Changed + +- [#1018](https://github.com/prettier/plugin-ruby/issues/1018) - rindek, kddnewton - Ensure brackets are used when matching an array pattern with a single element. +- [#906](https://github.com/prettier/plugin-ruby/issues/906) - Hansenq, kddnewton - Turn off the `Style/MultilineBlockChain` rubocop rule in our shipped configuration because multiple chained method calls with blocks can potentially conflict with rubocop's desired output. + +## [2.0.0-rc4] - 2021-10-18 + +### Added + +- [#993](https://github.com/prettier/plugin-ruby/pull/993) - kddnewton - Nicer error message if you don't have the necessary JavaScript files to run prettier. +- [#996](https://github.com/prettier/plugin-ruby/pull/996) - nbudin - Allow `@prettier/plugin-ruby` to run in yarn's plug'n'play mode. + +### Changed + +- [#1000](https://github.com/prettier/plugin-ruby/pull/1000) - nbudin, kddnewton - Fix for rescuing single top-level exceptions in `rescue` clauses. + +## [2.0.0-rc3] - 2021-10-01 + +### Changed + +- [#987](https://github.com/prettier/plugin-ruby/pull/9870) - valscion - Ignore stderr when checking for node <-> ruby connection clients, restoring the behavior of v1.x +- [#989](https://github.com/prettier/plugin-ruby/issues/989) - hubertjakubiak, kddnewton - Make sure comments after the keyword/lbrace are not moved inside the body of the statements of do and brace blocks. + +## [2.0.0-rc2] - 2021-09-30 + +### Added + +- [#979](https://github.com/prettier/plugin-ruby/issues/979) - ronocod, kddnewton - Alignment of `to_not` is explicitly allowed to not indent to better support rspec. +- [#894](https://github.com/prettier/plugin-ruby/issues/894) - mister-what, kddnewton - Add a warning that this plugin will not function with the plug'n'play filesystem provided by yarn berry. + +### Changed + +- [#943](https://github.com/prettier/plugin-ruby/issues/943) - valscion, kddnewton - Trailing call operators that are followed by comments should stay on the first line. + +## [2.0.0-rc1] - 2021-09-30 + +### Added + +- [#949](https://github.com/prettier/plugin-ruby/pull/949) - kddnewton - Converted over to using TypeScript for development. + +### Changed + +- [#958](https://github.com/prettier/plugin-ruby/issues/958) - mharris-figma, kddnewton - Handle optional `do` keyword in `for` loop expressions. +- [#926](https://github.com/prettier/plugin-ruby/issues/926) - jscheid, kddnewton - Better error handling in case certain expected keywords or operators are missing. +- [#819](https://github.com/prettier/plugin-ruby/issues/819) - coisnepe, kddnewton - Ensure that comments placed immediately after the left parenthesis of a method definition are not moved into the body of the methods. +- [#957](https://github.com/prettier/plugin-ruby/issues/957) - azz, kddnewton - Make it so that the format pragma does not have to be on the first line of the file. +- [#895](https://github.com/prettier/plugin-ruby/issues/895) - rsslldnphy, kddnewton - Ensure quotes are properly escaped in the content of a hash value for HAML attributes. +- [#900](https://github.com/prettier/plugin-ruby/issues/900) - rsslldnphy, kddnewton - Ensure that in a HAML line where you have interpolation inside of a tag content that you print it properly. +- [#929](https://github.com/prettier/plugin-ruby/issues/929) - ryanb, kddnewton - Deeply nested blocks should not break their call chains. +- [#935](https://github.com/prettier/plugin-ruby/pull/935) - nbudin, mlauter - Ensure embedded formatting heredocs are properly indented. +- [#975](https://github.com/prettier/plugin-ruby/pull/975) - kddnewton - Refactor the way we determine how to connect to the parser server. + +### Removed + +- [#976](https://github.com/prettier/plugin-ruby/pull/976) - kddnewton - Remove the `rubyNetcatCommand` option, as it should no longer be necessary. + +## [1.6.1] - 2021-06-30 + +### Changed + +- [#862](https://github.com/prettier/plugin-ruby/issues/862) - azz, kddnewton - Group together `.where.not` calls in method chains. +- [#863](https://github.com/prettier/plugin-ruby/issues/863) - azz, kddnewton - Fix up Sorbet `sig` block formatting when chaining method calls. +- [#908](https://github.com/prettier/plugin-ruby/issues/908) - Hansenq, kddnewton - Method chains with blocks should be properly indented. +- [#916](https://github.com/prettier/plugin-ruby/issues/916) - pbrisbin, kddnewton - Ensure all of the necessary files are present in the gem. +- [#917](https://github.com/prettier/plugin-ruby/issues/917) - jscheid, kddnewton - Ensure hash keys with dynamic symbols don't strip their quotes. + +## [1.6.0] - 2021-06-23 + +### Added + +- [#859](https://github.com/prettier/plugin-ruby/issues/859) - azz, kddnewton - Support the `--insert-pragma` option for the incremental adoption workflow. +- [#904](https://github.com/prettier/plugin-ruby/issues/904) - Hansenq, kddnewton - Support the `%s` symbol literal syntax. +- [#833](https://github.com/prettier/plugin-ruby/issues/883) - kddnewton - Support for prettier >= v2.3.0. + +### Changed + +- [#854](https://github.com/prettier/plugin-ruby/issues/854) - jflinter, kddnewton - Parentheses should not be stripped from optional RBS union types. +- [#888](https://github.com/prettier/plugin-ruby/issues/888) - MaxNotarangelo, kddnewton - Ensure parentheses wrap conditionals that get transformed into the modifier form when they're used within a binary node. +- [#874](https://github.com/prettier/plugin-ruby/issues/874) - yratanov, kddnewton - Ensure that method calls chained onto the ends of blocks still print their arguments. +- [#897](https://github.com/prettier/plugin-ruby/pull/897) - Hansenq - Reenable the `Layout/LineLength` rubocop rule in our shipped config so that line lengths for other cops are calculated correctly. + +## [1.5.5] - 2021-03-25 + +### Changed + +- [#841](https://github.com/prettier/plugin-ruby/issues/841) - LoganBarnett, kddnewton - Better error messaging for when unix sockets are not supported by netcat. +- [#844](https://github.com/prettier/plugin-ruby/issues/844) - andyw8, kddnewton - Ensure we ship all of the parsers with the prettier gem so that `rbprettier` can parse other languages as well. +- [#847](https://github.com/prettier/plugin-ruby/issues/847) - jflinter, kddnewton - Ensure parentheses are present on union return types in RBS. +- [#850](https://github.com/prettier/plugin-ruby/issues/850) - maethub, kddnewton - Ensure double quotes are used even when single quotes are requested for HAML attribute values. +- [#849](https://github.com/prettier/plugin-ruby/issues/849) - indirect, kddnewton - Support HAML version <= 5.1 multi-line attributes. +- [#810](https://github.com/prettier/plugin-ruby/issues/810) - valscion, kddnewton - Make it so that brace blocks containing heredocs have the correct end line so that they format subsequent statements correctly. + +## [1.5.4] - 2021-03-17 + +### Changed + +- [#835](https://github.com/prettier/plugin-ruby/issues/835) - valscion, kddnewton - Array splat operator should not get moved by leading comments. +- [#836](https://github.com/prettier/plugin-ruby/issues/836) - valscion, kddnewton - Array splat operator should not get moved by trailing comments. +- [#821](https://github.com/prettier/plugin-ruby/issues/821) - jscheid, kddnewton - Better error handling when using GNU netcat. + +## [1.5.3] - 2021-02-28 + +### Changed + +- [#812](https://github.com/prettier/plugin-ruby/issues/812) - valscion, kddnewton - Splats and blocks within args that have comments attached should place their respective operators in the right place. +- [#816](https://github.com/prettier/plugin-ruby/pull/816) - valscion - Document RuboCop's Style/Lambda should be disabled +- [#814](https://github.com/prettier/plugin-ruby/issues/814) - jscheid, kddnewton - Provide better errors when the source location of the error is known. + +## [1.5.2] - 2021-02-03 + +### Changed + +- kddnewton - Fix up `binary` node comparison operators so that it will handle either Symbol literals or the `@op` nodes which are incorrectly coming from JRuby (https://github.com/jruby/jruby/issues/6548). + +## [1.5.1] - 2021-01-27 + +### Changed + +- [#799](https://github.com/prettier/plugin-ruby/issues/799) - jscheid, kddnewton - Multi-byte characters shouldn't give invalid source string bounds. +- [#801](https://github.com/prettier/plugin-ruby/issues/801) - jscheid, kddnewton - When converting a conditional to the modifier form, make sure to add parentheses if there is a chained method call. +- [#803](https://github.com/prettier/plugin-ruby/issues/803) - jscheid, kddnewton - Fix `formatWithCursor` support to match new parser format. + +## [1.5.0] - 2021-01-21 + +### Added + +- kddnewton - Add `.rbi` as a file type that we support. + +### Changed + +- [#795](https://github.com/prettier/plugin-ruby/issues/795) djrodgerspryor, kddnewton - Trailing comments attached to empty arrays should not multiply. +- [#794](https://github.com/prettier/plugin-ruby/issues/794) djrodgerspryor, kddnewton - Fix embedded parser parsing by stripping common leading whitespace before passing on the content. +- [#793](https://github.com/prettier/plugin-ruby/issues/793) djrodgerspryor, kddnewton - Do not include trailing commas on arguments within `arg_paren` nodes if they could not be parsed with them (`command` and `command_call`). +- [#788](https://github.com/prettier/plugin-ruby/issues/788) clarkdave, kddnewton - Break child hashes within a multi-line hash regardless of whether or not they can fit on one line. +- kddnewton - Stop using `;` to separate empty class definitions, module definitions, and loops. + +## [1.4.0] - 2021-01-15 + +### Added + +- ianks, kddnewton - Use `netcat` to communicate to a parser server for better performance when formatting multiple files. + +### Changed + +- jeffcarbs, kddnewton - Long strings with interpolated expressions should only break if the contents in the original source is broken. +- johannesluedke, kddnewton - Fix for rescues with inline comments. +- johncsnyder, kddnewton - Comments should not attach to nodes beyond a double newline. +- blampe, kddnewton - Comments inside of a broken method chain get dropped. +- clarkdave, kddnewton - Don't ignore Sorbet `sig` transformations. + +## [1.3.0] - 2021-01-05 + +### Added + +- kddnewton - Handling of the RBS language. +- kddnewton - Incorporate the HAML plugin. + +## [1.2.5] - 2021-01-04 + +### Changed + +- nruth, kddnewton - Ensure unary operators on method calls that are sending operators get the correct scanner events. +- cvoege, kddnewton - Do not add parentheses when they're not needed to non-breaking command_calls with ternary arguments. +- valscion, kddnewton - Print method chains more nicely off array and hash literals. + +## [1.2.4] - 2021-01-03 + +### Added + +- andyw8 - Explain usage with Rubocop, as well as shipping a rubocop.yml config. + +### Changed + +- kddnewton - Reduce JSON size passing from Ruby process to node process by changing `char_start` -> `sc`, `char_end` -> `ec`, `start` -> `sl`, `end` -> `el`. +- kddnewton - Up the max buffer size between the Ruby and node processes to 15K. + +## [1.2.3] - 2021-01-02 + +### Changed + +- lukyth, kddnewton - Ensure if a ternary breaks into an `if..else..end` within a `command_call` node that parentheses are added. +- AlanFoster, kddnewton - Ensure you consume the optional `do` keyword on `while` and `until` loops so that it doesn't confuse the parser. +- AlanFoster, kddnewton - Ensure key-value pairs split on line when the key has a comment attached within a hash. +- AlanFoster, kddnewton - Fix for `for` loops that have multiple index variables. +- AlanFoster, kddnewton - Fix parsing very large files by reducing the size of the JSON output from the parser. +- AlanFoster, kddnewton - Ensure you don't skip parentheses if you're returning a value with the `not` unary operator. + +## [1.2.2] - 2021-01-01 + +### Changed + +- nathan-beam - Gem does not work with CMD/Powershell. +- blampe, kddnewton - Comments inside keyword parameters in method declarations are not printed. +- blampe, kddnewton - `command_call` nodes with unary operators incorrectly parse their operator. +- blampe, kddnewton - Returning multiple values where the first has parentheses was incorrectly removing the remaining values. +- johncsnyder, kddnewton - Call chains whose left-most receiver is a no-indent expression should not indent their entire chain. + +## [1.2.1] - 2020-12-27 + +### Changed + +- kddnewton - Handle single-line method definitions with parameters. +- kddnewton - Handle hash and array patterns nested within find patterns. +- kddnewton - Handle rightward assignment. +- kddnewton - Handle find patterns with named boundaries. +- kddnewton - Handle rightward assignment in conditionals. + +## [1.2.0] - 2020-12-26 + +### Added + +- kddnewton - Support for the `fndptn` node for Ruby 3.0 pattern matching. +- kddnewton - Support for Ruby 3.0+ single-line method definitions. + +## [1.1.0] - 2020-12-20 + +### Added + +- kddnewton - Now that the comments are all fixed up, we can support `# prettier-ignore` comments. + +### Changed + +- rindek, kddnewton - Do not remove parentheses when receiver looks like a constant. +- rindek, kddnewton - Do not remove parentheses when using the special `call` syntax with no arguments. +- ykpythemind - Do not change regexp bounds if the body has certain content. +- karanmandal, kddnewton - Correctly print for loops. +- rafbm, kddnewton - If there are method chains with arguments only at the end, we should group the method chain and the method args. + +## [1.0.1] - 2020-12-12 + +### Changed + +- steobrien, kddnewton - Ensure leading comments in empty array and hash literals do not duplicate. + +## [1.0.0] - 2020-12-11 + +### Changed + +- kddnewton - Do not unescape double quotes in a single quote string. +- kddnewton - Only force braces on regexp for spaces and equals if it's inside a command or command_call. +- kddnewton - Leave Sorbet type annotations in place. +- kddnewton - Don't group hash contents, just allow them to break with their parent node. +- kddnewton - Honor the UTF-8 lang passed in through ENV vars. + +## [1.0.0-rc2] - 2020-12-10 + +### Changed + +- kddnewton - Print hashes with consistent keys (e.g., if one key cannot be a hash label, use all hash rockets). +- kddnewton - Respect using `o` or not using `o` for octal numbers. +- kddnewton - Ensure `when` clauses with multiple predicates that can be split into multiple lines are split correctly. +- kddnewton - Ensure hash literal is split correctly when only its contents would fit on one line. +- kddnewton - Simplify `toProc` checks by not calling if the option is disabled. +- johncsnyder, kddnewton - Add `method_add_block` to the potential like of method calls that can be chained. +- kddnewton - Add the `rubyArrayLiteral` option for disabling automatically turning into array literals. + +## [1.0.0-rc1] - 2020-12-09 + +### Changed + +- kddnewton - Rename options to prep for v1.0 release. + - `addTrailingCommas` -> `trailingComma`, `"es5"` means `true` + - `inlineConditionals` and `inlineLoops` -> `rubyModifier` + - `preferHashLabels` -> `rubyHashLabel` + - `preferSingleQuotes` -> `rubySingleQuote` + - `toProcTransform` -> `rubyToProc` +- andyw8, kddnewton - Fix for Ruby `2.5.1` dyna_symbols. Turns out they were previously incorrectly reported as `xstring` nodes. +- andyw8, kddnewton - Fix for plain `rescue` nodes with only comments in the body. +- andyw8, kddnewton - Move declaration-type comments up to the line in the original source, as in: + +```ruby +def foo # :nodoc: + bar +end +``` + +The comment in the above example should stay in place. + +- janklimo - Respect special call syntax, e.g., `a.(1, 2, 3)` should remain the same. +- kddnewton - Fix up a bug with `ensure` being used in a `bodystmt` and not a `begin`. +- kddnewton - Fix up a bug with negative ranges, e.g., `-4..-3`. +- kddnewton - Fix up a bug with operator aliases, e.g., `alias << push`. +- kddnewton - Fix up a bug with calls and unary nodes, e.g., `!!foo&.bar`. +- kddnewton - Fix up a bug with multiple rescue clauses and comments, e.g., + +```ruby +begin +rescue Foo, Bar + # comment +end +``` + +- kddnewton - Handle string literals that start with `%Q`. +- kddnewton - Handle question method methods in the predicate of an if with a comment in the body. +- kddnewton - Fix bare `break` with comments immediately after. +- kddnewton - Fix for heredocs with comments immediately after the declaration. +- kddnewton - Fix for comments when you're defining a method whose name overlaps with a keyword. +- kddnewton - Don't automatically indent inside interpolated expressions from within a heredoc. +- kddnewton - Don't convert into string literal arrays if the elements have brackets. +- kddnewton - Ensure you break the parent when there is an assignment in the predicate of a loop. +- kddnewton - Fix up a bug with keyword aliases, e.g., `alias in within`. +- kddnewton - Force using braces for regex if a regex starts with a blank space. +- kddnewton - Force using braces for regex if a regex starts with an equals sign. +- kddnewton - Fix up a bug with constant aliases, e.g., `alias in IN`. +- andyw8, kddnewton - Ensure `rescue` comments stay on the same line as their declaration. + +## [0.22.0] - 2020-12-08 + +### Changed + +- flyerhzm - Print method chains by one indentation. +- mmcnl, kddnewton - Handle heredocs and blocks being passed to the same method. +- johncsnyder, kddnewton - Ensure correct formatting when breaking up conditionals with `inlineConditionals: false`. +- Rsullivan00 - Ensure that when ternaries as command arguments get broken into multiple lines we add the necessary parentheses. +- jbielick - Maintain parse order during if/unless modifier expressions +- flyerhzm - Slight prettifying of wrapped args if doc length is under a certain value. +- github0013, kddnewton - Ensure `not` keeps parentheses if they are being used. +- jbielick - Print heredocs consistently. +- kddnewton - Completely revamp the way we handle comments. +- kddnewton - Support `hshptn` and the remaining missing pattern matching syntax. + +## [0.21.0] - 2020-12-02 + +### Changed + +- kddnewton, ryan-hunter-pc - Explicitly handle `break` and `next` keyword parentheses. +- jbielick, kddnewton - Don't convert between `lambda {}` and `-> {}`. Technically it's breaking the semantics of the program. Also because lambda method call arguments can't handle everything that stabby lambda can. +- kddnewton - Turn off the `Symbol#to_proc` transform by default. +- janklimo, kddnewton - Properly handle trailing commas on hash arguments. +- coiti, kddnewton - Properly handle parentheses when necessary on if/unless statements and while/until loops. +- Rsullivan00 - Prevent `command` and `command_call` nodes from being turned into ternaries. +- kddnewton - Better handling of the `alias` node with and without comments. +- kddnewton - Better handling of the `BEGIN` and `END` nodes with and without comments. +- kddnewton - Much better handling of heredocs where now there is a consistent `heredoc` node instead of multiple. + +## [0.20.1] - 2020-09-04 + +### Changed + +- ftes, kddnewton - Properly escape HAML plain text statements that start with special HAML characters. + +### Removed + +- kddnewton - I'm stripping out the HAML plugin and putting it into its own package (`@prettier/plugin-haml`). It's become too difficult to maintain within this repo, and it's confusing for contributors because there are some things that work with Ruby and some things that don't. This is going to simplify maintenance. This should probably be a major version bump but since we're still pre `1.0` I'm going to leave it as a patch. + +## [0.20.0] - 2020-08-28 + +### Added + +- kddnewton - Allow embedded formatting on heredocs by the name placed at the start. For example, + + +```ruby +javascript = <<~JAVASCRIPT + const a=1; + const b=2; + return a+b; +JAVASCRIPT +``` + +### Changed + +- mmainz - Fix the encoding setting such that we're not overwriting the entire set of environment variables. + +## [0.19.1] - 2020-08-21 + +### Changed + +- Rsullivan00 - Do not tranform word-literal arrays when there is an escape sequence. +- steobrien, kddnewton - Do not indent heredocs with calls more than they should be. +- jpickwell - Include .simplecov in filenames +- github0013, kddnewton - Ensure we're parsing ruby files using UTF-8 regardless of the system encoding. + +## [0.19.0] - 2020-07-03 + +### Added + +- ryan-hunter-pc - Add the option to disable the `Symbol#to_proc` transform. +- ryan-hunter-pc], [@SViccari, kddnewton - Disable `Symbol#to_proc` transform when used as a key inside of a hash where the key is either `:if` or `:unless`. + +## [0.18.2] - 2020-05-01 + +### Changed + +- alse - Support `vscodeLanguageIds` for HAML. +- ShayDavidson, kddnewton - Don't allow replacing if/else with ternary if there's an assignment in the predicate. +- janklimo - Do not add an empty line after `rescue` when the block is empty. + +## [0.18.1] - 2020-04-05 + +### Changed + +- petevk, kddnewton - Use braces for block format iff it was originally a brace block, otherwise you could be changing precedence. For example: + + +```ruby +expect do + field 1 do + "foo" + end +end.to raise_error +``` + +should maintain its `do...end` and not switch to inline braces otherwise the brace might get associated with the `1`. + +- flyerhzm - Rewrite operators binary parser, as in: + + +```ruby +[ + '1111111111111111111111111111111111111111111111111111111111111111111111111', + 222 +] + + [1] +``` + +- ftes, kddnewton - When old-form dynamic attributes are added to a `div` tag in HAML, it was previously skipping printing the `%div`, which led to it being incorrectly displayed. +- ftes, kddnewton - Previously if you had a long tag declaration with attributes that made it hit the line limit, then the content of the tag would be pushed to the next line but indented one character too many. +- ftes, kddnewton - Don't explicitly require JSON if it has already been loaded, as this can lead to rubygems activation errors. +- mmainz, kddnewton - Handle heredocs as the receivers of call nodes, as in: + + +```ruby +foo = <<~TEXT.strip + bar +TEXT +``` + +- github0013, kddnewton - Leave parentheses in place if the value of a return node contains a binary with low operator precedence, as in: + + +```ruby +return (a or b) if c? +``` + +## [0.18.0] - 2020-03-17 + +### Added + +- kddnewton - Support for the `nokw_param` node for specifying when methods should no accept keywords, as in: + +```ruby +def foo(**nil) +end +``` + +- kddnewton - Support for the `args_forward` node for forwarding all types of arguments, as in: + +```ruby +def foo(...) + bar(...) +end +``` + +### Changed + +- ftes, kddnewton - Handled 3 or more classes on a node in HAML, as in: + +```haml +%table.table.is-striped.is-hoverable +``` + +- ftes, kddnewton - Better handling of indentation of `if/elsif/else`, `unless/elsif/else`, and `case/when` branches, as in: + +```haml +.column.is-12 + - if true + TRUE + - else + FALSE +``` + +- tobyndockerill - Format numbers with underscores after 4 digits, as opposed to 3. +- ianks - Improve performance by using `--disable-gems`. +- flyerhzm - Calls are grouped such that after an end parenthesis the following call will not be indented, as in: + + +```ruby +Config::Download.new( + 'prettier', + filename: 'prettier.yml', url: 'https://raw.githubusercontent.com/...' +) + .perform +``` + +will now be printed as: + +```ruby +Config::Download.new( + "prettier", + filename: "prettier.yml", + url: "https://raw.githubusercontent.com/..." +).perform +``` + +- pje, kddnewton - Method definition bodies (on `defs` nodes) should dedent if a helper method is called. As in: + + +```ruby +private def self.foo + 'bar' + end +``` + +should instead be indented as: + + +```ruby +private def self.foo + 'bar' +end +``` + +- masqita, kddnewton - Inline variable assignment within a predicate should force the conditional to break, as in: + +```ruby +array.each do |element| + if index = difference.index(element) + difference.delete_at(index) + end +end +``` + +- hafley66, kddnewton - Handle empty `while` and `until` blocks. +- Fruetel, kddnewton - Simplify string escape pattern by locking on any escape sequence. +- flyerhzm, kddnewton - Properly handle string quotes on symbols in hash keys. + +## [0.17.0] - 2019-12-12 + +### Added + +- matt-wratt - Better support for explicit `return` nodes with empty arrays or arrays with a single element. +- jrdioko, kddnewton - Alignment of `not_to` is explicitly allowed to not indent to better support rspec. + +### Changed + +- gin0606 - The max buffer being passed into the Ruby process is now up to 10MB. + +## [0.16.0] - 2019-11-14 + +### Added + +- mmainz, kddnewton - Support for extra commas in multiple assignment, as it changes the meaning. For example, + + +```ruby +a, = [1, 2, 3] +``` + +would previously get printed as `a = [1, 2, 3]`, which changes the value of `a` from `1` to the value of the entire array. + +- kddnewton - Experimental support for the HAMtemplate language. + +### Changed + +- github0013, kddnewton - Support proper string escaping when the original string in the source is wrapped in `%q|...|`. For example, `%q|\'|` should get printed as `"\'"`, where previously it was dropping the backslash. +- jamescostian, kddnewton - Force ternary breaking when using the lower-precendence operators `and` and `or`. For example, + + +```ruby +if x.nil? + puts 'nil' and return +else + x +end +``` + +the previous expression was being transformed into a ternary which was invalid ruby. Instead it now stays broken out into an if/else block. + +- localhostdotdev], [@joeyjoejoejr], [@eins78, kddnewton - Better support for embedded expressions inside heredocs. For example, + + +```ruby +<<-HERE + foo bar baz + #{qux} + foo bar baz +HERE +``` + +should remain formatted as it is. Whereas previously due to the way the lines were split, you would sometimes end up with it breaking after `#{`. + +- jamescostian, kddnewton - Fix up `return` node printing. When returning multiple values, you need to return an array literal as opposed to using parentheses. + +## [0.15.1] - 2019-11-05 + +### Changed + +- AlanFoster - Add `bin/lex` for viewing the tokenized result of Ripper on Ruby code. +- jakeprime, kddnewton - When predicates from within an `if`, `unless`, `while`, or `until` loop break the line, they should be aligned together. For example, + + +```ruby +if foooooo || barrrrrr + baz +end +``` + +If the line was set to very short, the binary node should be aligned to 3 spaces from the left of the file (which aligns with the `if`, it would be more for `unless`). So it would look like: + + +```ruby +if foooooo || + barrrrrr + baz +end +``` + +- jamescostian], [@AlanFoster - Empty `if`, and `unless` conditionals are now handled gracefully: + + +```ruby +if foo? +end +``` + +- mmainz, kddnewton - Hash keys are not converted to keyword syntax if they would make invalid symbols. For example, + + +```ruby +{ :[] => nil } +``` + +cannot be translated into `[]:` as that is an invalid symbol. Instead, it stays with the hash rocket syntax. + +- cldevs, kddnewton - Do not attempt to format the insides of xstring literals (string that get sent to the command line surrounded by backticks or `%x`). +- cldevs, kddnewton - When predicates for `if`, `unless`, `while`, or `until` nodes contain an assignment, we can't know for sure that it doesn't modify the body. In this case we need to always break and form a multi-line block. +- MarcManiez, kddnewton - When the return value of `if`, `unless`, `while`, or `until` nodes are assigned to anything other than a local variable, we need to wrap them in parentheses if we're changing to the modifier form. This is because the following expressions have different semantic meaning: + + +```ruby +hash[:key] = break :value while false +hash[:key] = while false do break :value end +``` + +The first one will not result in an empty hash, whereas the second one will result in `{ key: nil }`. In this case what we need to do for the first expression to align is wrap it in parens, as in: + + +```ruby +hash[:key] = (break :value while false) +``` + +That will guarantee that the expressions are equivalent. + +- AlanFoster - Fix crashes that were happening with `ignored_nl` nodes. + +## [0.15.0] - 2019-08-06 + +### Changed + +- dudeofawesome, kddnewton - If xstring literals (command line calls surrounded by backticks) break, then we indent and place the command on a new line. Previously, this was resulting in new lines getting added each time the code was formatted. Now this happens correctly. +- krachtstefan, kddnewton - When a `while` or `until` loop modifies a `begin...end` statement, it must remain in the modifier form or else it changes sematic meaning. For example, + + +```ruby +begin + foo +end while bar +``` + +cannot be transformed into: + + +```ruby +while bar + foo +end +``` + +because that would never execute `foo` if `bar` is falsy, whereas in the initial example it would have. + +- jviney], kddnewton - When transforming a block into the `Symbol#to_proc` syntax from within a list of arguments inside of an `aref` node (i.e., `foo[:bar.each`), we can't put the block syntax inside the brackets. +- jakeprime, kddnewton - Values for the `return` keyword that broke the line were previously just printed as they were, which breaks if you have a block expression like an `if` or `while`. For example, + + +```ruby +return foo ? bar : baz +``` + +if the line was set to very short would be printed as: + + +```ruby +return if foo + bar +else + baz +end +``` + +which wouldn't work. Instead, they now get printed with parentheses around the value, as in: + + +```ruby +return( + if foo + bar + else + baz + end +) +``` + +- jakeprime, kddnewton - When switching from a double-quoted string to a single-quoted string that contained escaped double quotes, the backslashes would stay in the string. As in: + + +```ruby +"Foo \"Bar\" Baz" +``` + +would get formatted as: + + +```ruby +'Foo \"Bar\" Baz' +``` + +but now gets formatted as: + + +```ruby +'Foo "Bar" Baz' +``` + +## [0.14.0] - 2019-07-17 + +### Added + +- kddnewton - Support for pattern matching for variables and array patterns. Currently waiting on Ripper support for hash patterns. For examples, check out the [test/js/patterns.test.js](test/js/patterns.test.js) file. + +### Changed + +- jviney, kddnewton - if/else blocks that had method calls on the end of them that were also transformed into ternaries need to have parens added to them. For example, + + +```ruby +if foo + 1 +else + 2 +end.to_s +``` + +now correctly gets transformed into: + + +```ruby +(foo ? 1 : 2).to_s +``` + +- acrewdson, kddnewton - Fixed a bug where multiple newlines at the end of the file would cause a crash. +- jviney, kddnewton - If a variable is assigned inside of the predicate of a conditional, then we can't change it into the single-line version as this breaks. For example, + + +```ruby +if foo = 1 + foo +end +``` + +must stay the same. + +## [0.13.0] - 2019-07-05 + +### Added + +- kddnewton - Added `locStart` and `locEnd` functions to support `--cursor-offset`. + +### Changed + +- xipgroc, kddnewton - Comments inside of `do...end` blocks that preceeded `call` nodes were associating the comment with the `var_ref` instead of the `call` itself. For example, + + +```ruby +foo.each do |bar| + # comment + bar.baz + bar.baz +end +``` + +would get printed as + + +```ruby +foo.each do |bar| + # comment + bar + .baz + bar.baz +end +``` + +but now gets printed correctly. + +- petevk, kddnewton - Double splats inside a hash were previously failing to print. For example, + + +```ruby +{ foo: "bar", **baz } +``` + +would fail to print, but now works. + +## [0.12.3] - 2019-05-16 + +### Changed + +- kddnewton - Move arg, assign, constant, flow, massign, operator, scope, and statement nodes into their own files. +- kddnewton - Move `@int`, `access_ctrl`, `assocsplat`, `block_var`, `else`, `number_arg`, `super`, `undef`, `var_ref`, and `var_ref` as well as various call and symbol nodes into appropriate files. +- kddnewton - Better support for excessed commas in block args. Previously `proc { |x,| }` would add an extra space, but now it does not. +- kddnewton - Add a lot more documentation to the parser. +- glejeune, kddnewton - Previously, the unary `not` operator inside a ternary (e.g., `a ? not(b) : c`) would break because it wouldn't add parentheses, but now it adds them. +- kddnewton - `if` and `unless` nodes used to not be able to handle if a comment was the only statement in the body. For example, + + +```ruby +if foo + # comment +end +``` + +would get printed as + + +```ruby +# comment if foo +``` + +Now the `if` and `unless` printers check for the presence of single comments. + +- JoshuaKGoldberg, kddnewton - Fixes an error where `command` nodes within `def` nodes would fail to format if it was only a single block argument. For example, + + +```ruby +def curry(&block) + new &block +end +``` + +would fail, but now works. + +- xipgroc, kddnewton - Comments on lines with array references were previously deleting the array references entirely. For example, + + +```ruby +array[index] # comment +``` + +would previously result in `array[]`, but now prints properly. + +## [0.12.2] - 2019-04-30 + +### Changed + +- kddnewton - When symbol literal hash keys end with `=`, they cannot be transformed into hash labels. +- xipgroc, kddnewton - Fixed when blocks on methods with no arguments are transformed into `to_proc` syntax. + +## [0.12.1] - 2019-04-22 + +### Changed + +- kddnewton - If a lambda literal is nested under a `command` or `command_call` node anywhere in the heirarchy, then it needs to use the higher-precedence `{ ... }` braces as opposed to the `do ... end` delimiters. +- jpickwell, kddnewton - Calling `super` with a block and no args was causing the parser to fail when attempting to inspect lambda nodes. +- kddnewton - Support better breaking within interpolation by grouping the interpolated content. + +## [0.12.0] - 2019-04-18 + +### Added + +- kddnewton - Automatically convert `lambda { ... }` method calls into `-> { ... }` literals. + +## [0.11.0] - 2019-04-18 + +### Added + +- kddnewton - Support for parsing things with a ruby shebang (e.g., `#!/usr/bin/env ruby` or `#!/usr/bin/ruby`). +- kddnewton - Big tests refactor. +- kddnewton - Make multiple `when` predicates break at 80 chars and then wrap to be inline with the other predicates. +- kddnewton - Automatically add underscores in large numbers that aren't already formatted. +- AlanFoster - Better support for inline access control modifiers. +- jpickwell, kddnewton - Better support for heredocs in hash literals. +- kddnewton - Better support for heredocs in array literals. +- kddnewton - Support automatically transforming `def/begin/rescue/end/end` into `def/rescue/end`. + +### Changed + +- deecewan - Fixed support for dynamic string hash keys. +- kddnewton - Moved `case/when` into its own file and added better documentation. +- kddnewton - Moved `begin/rescue` into its own file. +- AlanFoster - Automatically add newlines around access modifiers. +- kddnewton - Alignment of command calls with arguments is fixed. +- aaronjensen, kddnewton - Alignment of `to` is explicitly allowed to not indent to better support rspec. +- kddnewton - Fix up the `to_proc` transform so that it works with other argument handling appropriately. +- kddnewton - Fixed regression on regexp comments. +- CodingItWrong, kddnewton - Fix up block delimiters when nested inside a `command` or `command_call` node. +- kddnewton - Moved hashes into its own file. + ## [0.10.0] - 2019-03-25 + ### Added -- Support for block-local variables. -- Support for dyna-symbols that are using single quotes. + +- kddnewton - Support for block-local variables. +- kddnewton - Support for dyna-symbols that are using single quotes. ### Changed -- Force method calls after arrays, blocks, hashes, and xstrings to hang onto the end of the previous nodes. -- Check before anything else for an invalid ruby version. + +- kddnewton - Force method calls after arrays, blocks, hashes, and xstrings to hang onto the end of the previous nodes. +- kddnewton - Check before anything else for an invalid ruby version. ## [0.9.1] - 2019-03-24 + ### Changed -- Better support string quotes by favoring what the user chose if the string contains escape patterns. -- Better support heredocs within method calls. + +- kddnewton - Better support string quotes by favoring what the user chose if the string contains escape patterns. +- kddnewton - Better support heredocs within method calls. ## [0.9.0] - 2019-03-18 + ### Added -- Support the `hasPragma` function. -- Support the new `number_arg` node type in Ruby 2.7. + +- kddnewton - Support the `hasPragma` function. +- kddnewton - Support the new `number_arg` node type in Ruby 2.7. ### Changed -- Limit the number of nodes that are allowed to turn into ternary expressions. + +- kddnewton - Limit the number of nodes that are allowed to turn into ternary expressions. ## [0.8.0] - 2019-03-08 + ### Added -- [INTERNAL] Add `eslint` and fix up existing violations. -- Add the infra for the `prettier` ruby gem. (Thanks to @AlanFoster.) -- Add a `rake` task for easier process integration for the ruby gem. -- Handle direct interpolation of strings with %w array literals (i.e., `["#{foo}"]` should not be transformed into a %w array). + +- kddnewton - Add `eslint` and fix up existing violations. +- AlanFoster - Add the infra for the `prettier` ruby gem. +- kddnewton - Add a `rake` task for easier process integration for the ruby gem. +- kddnewton - Handle direct interpolation of strings with %w array literals (i.e., `["#{foo}"]` should not be transformed into a %w array). ### Changed -- Fix string escaping for hex digit bit patterns when there's only one character after the "x". -- Don't allow line breaks between brace block params. (Thanks to @AlanFoster.) -- [INTERNAL] Switch over the array.rb test case to minitest. (Thanks to @johnschoeman.) -- [INTERNAL] Test improvements to allow running in parallel. (Thanks to @AlanFoster.) -- [INTERNAL] Switch over assign.rb test case to minitest. (Thanks to @johnschoeman.) -- [INTERNAL] Add a contributing guide. (Thanks to @AlanFoster.) -- Handle longer command nodes. (Thanks to @AlanFoster.) -- Changed the ruby executable within the `prettier` gem to `rbprettier` for easier autocomplete. + +- kddnewton - Fix string escaping for hex digit bit patterns when there's only one character after the "x". +- AlanFoster - Don't allow line breaks between brace block params. +- johnschoeman - Switch over the array.rb test case to minitest. +- AlanFoster - Test improvements to allow running in parallel. +- johnschoeman - Switch over assign.rb test case to minitest. +- AlanFoster - Add a contributing guide. +- AlanFoster - Handle longer command nodes. +- kddnewton - Changed the ruby executable within the `prettier` gem to `rbprettier` for easier autocomplete. ### Removed -- All instances of the spread (`...`) operator so that we can support older versions of node. + +- kddnewton - All instances of the spread (`...`) operator so that we can support older versions of node. ## [0.7.0] - 2019-02-24 + ### Changed -- Support checking for escaping within strings to force double quotes (e.g., "\n"). -- Handle cases with empty class and module declarations that need to break. (Thanks to @RossKinsella for the report.) -- [INTERNAL] Align the `bin/print` and `bin/sexp` API to support `bin/print` taking a filepath. (Thanks to @AlanFoster.) -- Support lambdas that don't break and are inline. (Thanks to @AndrewRayCode for the report.) -- [INTERNAL] Switch over the numbers.rb test to minitest. (Thanks to @AlanFoster.) -- [INTERNAL] Switch over the kwargs.rb test to minitest. (Thanks to @AlanFoster.) -- [INTERNAL] Bail out early if the Ruby input is invalid. (Thanks to @AlanFoster.) -- Support `__END__` content. -- Fix up issue with whitespace being added within regexp that are multiline. (Thanks to @AlanFoster.) -- Better support for destructuring within multi assignment. (Thanks to @AlanFoster.) -- [INTERNAL] Switch `next` test over to minitest. -- Handle multiple arguments to `next` with a space between. -- Handle multi-line conditional predicate (should align with keyword). (Thanks to @AndrewRayCode for the report.) -- Properly support adding trailing commas with and without blocks. (Thanks to @aaronjensen for the report.) -- Fix regression of handling comments within arrays on array literals. (Thanks to @AlanFoster for the report.) -- Support multiple arguments to `undef`. (Thanks to @AlanFoster.) + +- kddnewton - Support checking for escaping within strings to force double quotes (e.g., "\n"). +- RossKinsella, kddnewton - Handle cases with empty class and module declarations that need to break. +- AlanFoster - Align the `bin/print` and `bin/sexp` APto support `bin/print` taking a filepath. +- AndrewRayCode, kddnewton - Support lambdas that don't break and are inline. +- AlanFoster - Switch over the numbers.rb test to minitest. +- AlanFoster - Switch over the kwargs.rb test to minitest. +- AlanFoster - Bail out early if the Ruby input is invalid. +- kddnewton - Support `__END__` content. +- AlanFoster - Fix up issue with whitespace being added within regexp that are multiline. +- AlanFoster - Better support for destructuring within multi assignment. +- kddnewton - Switch `next` test over to minitest. +- kddnewton - Handle multiple arguments to `next` with a space between. +- AndrewRayCode, kddnewton - Handle multi-line conditional predicate (should align with keyword). +- aaronjensen, kddnewton - Properly support adding trailing commas with and without blocks. +- AlanFoster, kddnewton - Fix regression of handling comments within arrays on array literals. +- AlanFoster - Support multiple arguments to `undef`. ## [0.6.3] - 2019-02-18 + ### Changed -- [INTERNAL] Switch over `binary` fixture to minitest. -- [INTERNAL] Reconfigure parser into multiple layer modules so that it's easier to understand and manage. -- Handle comments from within `begin`, `rescue`, `ensure`, `while`, and `until` nodes. -- Properly indent heredocs without taking into account current indentation level. + +- kddnewton - Switch over `binary` fixture to minitest. +- kddnewton - Reconfigure parser into multiple layer modules so that it's easier to understand and manage. +- kddnewton - Handle comments from within `begin`, `rescue`, `ensure`, `while`, and `until` nodes. +- kddnewton - Properly indent heredocs without taking into account current indentation level. ## [0.6.2] - 2019-02-17 + ### Changed -- Handle regexp suffixes. (Thanks to @AlanFoster.) -- [INTERNAL] Add support for testing the test fixtures with minitest. -- [INTERNAL] Switch over `alias` and `regexp` tests to minitest. -- Break up method args to split into multiple lines. (Thanks to @aaronjensen for the report.) -- Handle blocks args when trailing commas are on. (Thanks to @christoomey for the report.) + +- AlanFoster - Handle regexp suffixes. +- kddnewton - Add support for testing the test fixtures with minitest. +- kddnewton - Switch over `alias` and `regexp` tests to minitest. +- aaronjensen, kddnewton - Break up method args to split into multiple lines. +- christoomey, kddnewton - Handle blocks args when trailing commas are on. ## [0.6.1] - 2019-02-15 + ### Changed -- Fix Ruby 2.5 inline comments on `args_add_block` nodes. (Thanks to @meleyal for the report.) -- Support passing `super()` explicitly with no arguments. (Thanks to @meleyal for the report.) + +- meleyal, kddnewton - Fix Ruby 2.5 inline comments on `args_add_block` nodes. +- meleyal, kddnewton - Support passing `super()` explicitly with no arguments. ## [0.6.0] - 2019-02-14 + ### Added -- Handle non UTF-8 comments. -- Handle non UTF-8 identifiers. -- Handle non UTF-8 strings. -- Handle empty parens. -- Handle rescue with splats preceeding the exception names. + +- kddnewton - Handle non UTF-8 comments. +- kddnewton - Handle non UTF-8 identifiers. +- kddnewton - Handle non UTF-8 strings. +- kddnewton - Handle empty parens. +- kddnewton - Handle rescue with splats preceeding the exception names. ### Changed -- Use `JSON::fast_generate` to get the s-expressions back from the parser. -- Handle broken lambdas from within `command` and `command_call` nodes. (Thanks to @NoahTheDuke for the report.) + +- kddnewton - Use `JSON::fast_generate` to get the s-expressions back from the parser. +- NoahTheDuke, kddnewton - Handle broken lambdas from within `command` and `command_call` nodes. ## [0.5.2] - 2019-02-13 + ### Changed -- Support embedded expressions within strings that contain only keywords, as in `"#{super}"`. + +- kddnewton - Support embedded expressions within strings that contain only keywords, as in `"#{super}"`. ## [0.5.1] - 2019-02-13 + ### Changed -- Force `do` blocks that we know have to be `do` blocks to break. (Thanks to @yuki24 for the report.) -- Handle `command` and `command_call` nodes `do` blocks by forcing them to break. (Thanks to @kmcq for the report.) -- Attach comments to full hash association nodes, not just the value. (Thanks to @ashfurrow for the report.) + +- yuki24, kddnewton - Force `do` blocks that we know have to be `do` blocks to break. +- kmcq, kddnewton - Handle `command` and `command_call` nodes `do` blocks by forcing them to break. +- ashfurrow, kddnewton - Attach comments to full hash association nodes, not just the value. ## [0.5.0] - 2019-02-13 + ### Added -- Automatically convert arrays of all string literals to %w arrays. -- Automatically convert arrays of all symbol literals to %i arrays. + +- kddnewton - Automatically convert arrays of all string literals to %w arrays. +- kddnewton - Automatically convert arrays of all symbol literals to %i arrays. ### Changed -- [INTERNAL] Move the `args_add` and `args_new` handling into the parser. -- Change `command_call` nodes to properly indent when broken and to not add a trailing comma. (Thanks to @uri for the report.) -- Rename the `trailingComma` option to `addTrailingCommas` to not conflict with the JS option. + +- kddnewton - Move the `args_add` and `args_new` handling into the parser. +- uri, kddnewton - Change `command_call` nodes to properly indent when broken and to not add a trailing comma. +- kddnewton - Rename the `trailingComma` option to `addTrailingCommas` to not conflict with the JS option. ## [0.4.1] - 2019-02-12 + ### Changed -- [INTERNAL] Provide the `makeList` utility for the nodes that are lists from within ripper. -- Again, this time for real, properly escape strings. (Thanks to @awinograd for the report.) -- Fix up trailing commas on command calls. + +- kddnewton - Provide the `makeList` utility for the nodes that are lists from within ripper. +- awinograd, kddnewton - Again, this time for real, properly escape strings. +- kddnewton - Fix up trailing commas on command calls. ## [0.4.0] - 2019-02-12 + ### Added -- Support the `trailingComma` configuration option (defaults to `false`). (Thanks to @Overload119 for the request.) + +- Overload119, kddnewton - Support the `trailingComma` configuration option (defaults to `false`). ### Changed -- Pass the code to be formatted over `stdin`. (Thanks to @NoahTheDuke for the report.) + +- NoahTheDuke, kddnewton - Pass the code to be formatted over `stdin`. ## [0.3.7] - 2019-02-11 + ### Changed -- Split up statements even if they started on the same line with `;`s unless they are within an embedded expression. -- Properly handle escaped quotes within strings. + +- kddnewton - Split up statements even if they started on the same line with `;`s unless they are within an embedded expression. +- kddnewton - Properly handle escaped quotes within strings. ## [0.3.6] - 2019-02-10 + ### Changed -- Support the `not` operator properly. (Thanks to @AlanFoster for the report.) -- Handle comments properly inside `if`, `unless`, and `when` nodes. (Thanks to @AlanFoster for the report.) + +- AlanFoster, kddnewton - Support the `not` operator properly. +- AlanFoster, kddnewton - Handle comments properly inside `if`, `unless`, and `when` nodes. ## [0.3.5] - 2019-02-09 + ### Changed -- Handle lonely operators in Ruby `2.5`. + +- kddnewton - Handle lonely operators in Ruby `2.5`. ## [0.3.4] - 2019-02-09 + ### Changed -- Comments are now properly attached inside `defs` nodes. -- Support multiple inline comments on nodes. -- Support inline comments from within the `EXPR_END|EXPR_LABEL` lexer state. -- Stop transforming multistatement blocks with `to_proc`. (Thanks to @cbothner.) -- `do` blocks necessarily need to break their parent nodes. -- Handle `next` node edge case with `args_add` as the body. (Thanks to @eins78 for the report.) + +- kddnewton - Comments are now properly attached inside `defs` nodes. +- kddnewton - Support multiple inline comments on nodes. +- kddnewton - Support inline comments from within the `EXPR_END|EXPR_LABEL` lexer state. +- cbothner - Stop transforming multistatement blocks with `to_proc`. +- kddnewton - `do` blocks necessarily need to break their parent nodes. +- eins78, kddnewton - Handle `next` node edge case with `args_add` as the body. ## [0.3.3] - 2019-02-09 + ### Changed -- Command nodes within conditionals now break parents to disallow them from being turned into ternary expressions. (Thanks to @bugthing for the report.) -- Properly escape double quotes when using `preferSingleQuotes: false`. (Thanks to @awinograd for the report.) + +- bugthing, kddnewton - Command nodes within conditionals now break parents to disallow them from being turned into ternary expressions. +- awinograd, kddnewton - Properly escape double quotes when using `preferSingleQuotes: false`. ## [0.3.2] - 2019-02-09 + ### Changed -- [INTERNAL] Don't define duplicated methods in the parser. -- Let prettier know about `.rb` and `.rake` files so you don't have to specify the parser when running. -- Renamed the package to @prettier/plugin-ruby. + +- kddnewton - Don't define duplicated methods in the parser. +- kddnewton - Let prettier know about `.rb` and `.rake` files so you don't have to specify the parser when running. +- kddnewton - Renamed the package to @prettier/plugin-ruby. ## [0.3.1] - 2019-02-07 + ### Changed -- Automatically add parens to method declarations. -- Handle comments on bare hash assocs. -- Handle `method_add_block` nodes where the statements may be nested one more level. -- Handle heredocs nested no matter how many levels deep. + +- kddnewton - Automatically add parens to method declarations. +- kddnewton - Handle comments on bare hash assocs. +- kddnewton - Handle `method_add_block` nodes where the statements may be nested one more level. +- kddnewton - Handle heredocs nested no matter how many levels deep. ## [0.3.0] - 2019-02-07 + ### Added -- Support squiggly heredocs. -- Support straight heredocs. + +- kddnewton - Support squiggly heredocs. +- kddnewton - Support straight heredocs. ### Changed -- Ignore current indentation when creating embdocs so that `=begin` is always at the beginning of the line. -- [INTERNAL] Move `regexp_add` and `regexp_new` handling into the parser. -- [INTERNAL] Move `xstring_add` and `xstring_new` handling into the parser. -- [INTERNAL] Move `string_add` and `string_content` handling into the parser. -- [INTERNAL] Move `mrhs_add` and `mrhs_new` handling into the parser. -- [INTERNAL] Move `mlhs_add` and `mlhs_new` handling into the parser. + +- kddnewton - Ignore current indentation when creating embdocs so that `=begin` is always at the beginning of the line. +- kddnewton - Move `regexp_add` and `regexp_new` handling into the parser. +- kddnewton - Move `xstring_add` and `xstring_new` handling into the parser. +- kddnewton - Move `string_add` and `string_content` handling into the parser. +- kddnewton - Move `mrhs_add` and `mrhs_new` handling into the parser. +- kddnewton - Move `mlhs_add` and `mlhs_new` handling into the parser. ## [0.2.1] - 2019-02-06 + ### Changed -- Handle brace blocks on commands properly. -- Break parent and return `do` blocks when called from a `command` node. -- Handle edge cases with `if` statements where there is no body of the if (so it can't be converted to a ternary). + +- kddnewton - Handle brace blocks on commands properly. +- kddnewton - Break parent and return `do` blocks when called from a `command` node. +- kddnewton - Handle edge cases with `if` statements where there is no body of the if (so it can't be converted to a ternary). ## [0.2.0] - 2019-02-06 + ### Added -- Handle `methref` nodes from Ruby `2.7`. -- Allow `module` nodes to shorten using `;` when the block is empty. + +- kddnewton - Handle `methref` nodes from Ruby `2.7`. +- kddnewton - Allow `module` nodes to shorten using `;` when the block is empty. ### Changed -- Handle splat within an array, as in `[1, 2, *foo]`. -- Disallow comments from being attached to intermediary regex nodes. -- Fix `to_proc` transforms to reference the method called as opposed to the parameter name. -- [INTERNAL] Change statement lists to be generated within the parser instead of the printer, thereby allowing finer control over comments. -- [INTERNAL] Completely revamp comment parsing by switching off the internal lexer state from `ripper`. This should drastically increase accuracy of comment parsing in general, and set us up for success in the future. -- Allow comments to be attached to `CHAR` nodes. -- [INTERNAL] Disallow comments from being attached to `args_new` nodes. -- [INTERNAL] Track start and end lines so we can better insert block comments. -- [INTERNAL] Handle intermediary array nodes in the parse for better comment handling. + +- kddnewton - Handle splat within an array, as in `[1, 2, *foo]`. +- kddnewton - Disallow comments from being attached to intermediary regex nodes. +- kddnewton - Fix `to_proc` transforms to reference the method called as opposed to the parameter name. +- kddnewton - Change statement lists to be generated within the parser instead of the printer, thereby allowing finer control over comments. +- kddnewton - Completely revamp comment parsing by switching off the internal lexer state from `ripper`. This should drastically increase accuracy of comment parsing in general, and set us up for success in the future. +- kddnewton - Allow comments to be attached to `CHAR` nodes. +- kddnewton - Disallow comments from being attached to `args_new` nodes. +- kddnewton - Track start and end lines so we can better insert block comments. +- kddnewton - Handle intermediary array nodes in the parse for better comment handling. ## [0.1.2] - 2019-02-05 + ### Changed -- Handle guard clauses that return with no parens. + +- kddnewton - Handle guard clauses that return with no parens. ## [0.1.1] - 2019-02-05 + ### Changed -- Handle class method calls with the `::` operator. -- Handle strings with apostrophes when using `preferSingleQuote`. -- [INTERAL] Have travis run multiple ruby versions. -- Explicitly fail if ruby version is < `2.5`. -- Disallow comments from being attached to intermediary string nodes. + +- kddnewton - Handle class method calls with the `::` operator. +- kddnewton - Handle strings with apostrophes when using `preferSingleQuote`. +- kddnewton - Have travis run multiple ruby versions. +- kddnewton - Explicitly fail if ruby version is < `2.5`. +- kddnewton - Disallow comments from being attached to intermediary string nodes. ## [0.1.0] - 2019-02-04 + ### Added + - Initial release 🎉 -[Unreleased]: https://github.com/prettier/plugin-ruby/compare/v0.10.0...HEAD +[unreleased]: https://github.com/prettier/plugin-ruby/compare/v4.0.4...HEAD +[4.0.4]: https://github.com/prettier/plugin-ruby/compare/v4.0.3...v4.0.4 +[4.0.3]: https://github.com/prettier/plugin-ruby/compare/v4.0.2...v4.0.3 +[4.0.2]: https://github.com/prettier/plugin-ruby/compare/v4.0.1...v4.0.2 +[4.0.1]: https://github.com/prettier/plugin-ruby/compare/v4.0.0...v4.0.1 +[4.0.0]: https://github.com/prettier/plugin-ruby/compare/v3.2.2...v4.0.0 +[3.2.2]: https://github.com/prettier/plugin-ruby/compare/v3.2.1...v3.2.2 +[3.2.1]: https://github.com/prettier/plugin-ruby/compare/v3.2.0...v3.2.1 +[3.2.0]: https://github.com/prettier/plugin-ruby/compare/v3.1.2...v3.2.0 +[3.1.2]: https://github.com/prettier/plugin-ruby/compare/v3.1.1...v3.1.2 +[3.1.1]: https://github.com/prettier/plugin-ruby/compare/v3.1.0...v3.1.1 +[3.1.0]: https://github.com/prettier/plugin-ruby/compare/v3.0.0...v3.1.0 +[3.0.0]: https://github.com/prettier/plugin-ruby/compare/v2.1.0...v3.0.0 +[2.1.0]: https://github.com/prettier/plugin-ruby/compare/v2.0.0...v2.1.0 +[2.0.0]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc4...v2.0.0 +[2.0.0-rc4]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc3...v2.0.0-rc4 +[2.0.0-rc3]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc2...v2.0.0-rc3 +[2.0.0-rc2]: https://github.com/prettier/plugin-ruby/compare/v2.0.0-rc1...v2.0.0-rc2 +[2.0.0-rc1]: https://github.com/prettier/plugin-ruby/compare/v1.6.1...v2.0.0-rc1 +[1.6.1]: https://github.com/prettier/plugin-ruby/compare/v1.6.0...v1.6.1 +[1.6.0]: https://github.com/prettier/plugin-ruby/compare/v1.5.5...v1.6.0 +[1.5.5]: https://github.com/prettier/plugin-ruby/compare/v1.5.4...v1.5.5 +[1.5.4]: https://github.com/prettier/plugin-ruby/compare/v1.5.3...v1.5.4 +[1.5.3]: https://github.com/prettier/plugin-ruby/compare/v1.5.2...v1.5.3 +[1.5.2]: https://github.com/prettier/plugin-ruby/compare/v1.5.1...v1.5.2 +[1.5.1]: https://github.com/prettier/plugin-ruby/compare/v1.5.0...v1.5.1 +[1.5.0]: https://github.com/prettier/plugin-ruby/compare/v1.4.0...v1.5.0 +[1.4.0]: https://github.com/prettier/plugin-ruby/compare/v1.3.0...v1.4.0 +[1.3.0]: https://github.com/prettier/plugin-ruby/compare/v1.2.5...v1.3.0 +[1.2.5]: https://github.com/prettier/plugin-ruby/compare/v1.2.4...v1.2.5 +[1.2.4]: https://github.com/prettier/plugin-ruby/compare/v1.2.3...v1.2.4 +[1.2.3]: https://github.com/prettier/plugin-ruby/compare/v1.2.2...v1.2.3 +[1.2.2]: https://github.com/prettier/plugin-ruby/compare/v1.2.1...v1.2.2 +[1.2.1]: https://github.com/prettier/plugin-ruby/compare/v1.2.0...v1.2.1 +[1.2.0]: https://github.com/prettier/plugin-ruby/compare/v1.1.0...v1.2.0 +[1.1.0]: https://github.com/prettier/plugin-ruby/compare/v1.0.1...v1.1.0 +[1.0.1]: https://github.com/prettier/plugin-ruby/compare/v1.0.0...v1.0.1 +[1.0.0]: https://github.com/prettier/plugin-ruby/compare/v1.0.0-rc2...v1.0.0 +[1.0.0-rc2]: https://github.com/prettier/plugin-ruby/compare/v1.0.0-rc1...v1.0.0-rc2 +[1.0.0-rc1]: https://github.com/prettier/plugin-ruby/compare/v0.22.0...v1.0.0-rc1 +[0.22.0]: https://github.com/prettier/plugin-ruby/compare/v0.21.0...v0.22.0 +[0.21.0]: https://github.com/prettier/plugin-ruby/compare/v0.20.1...v0.21.0 +[0.20.1]: https://github.com/prettier/plugin-ruby/compare/v0.20.0...v0.20.1 +[0.20.0]: https://github.com/prettier/plugin-ruby/compare/v0.19.1...v0.20.0 +[0.19.1]: https://github.com/prettier/plugin-ruby/compare/v0.19.0...v0.19.1 +[0.19.0]: https://github.com/prettier/plugin-ruby/compare/v0.18.2...v0.19.0 +[0.18.2]: https://github.com/prettier/plugin-ruby/compare/v0.18.1...v0.18.2 +[0.18.1]: https://github.com/prettier/plugin-ruby/compare/v0.18.0...v0.18.1 +[0.18.0]: https://github.com/prettier/plugin-ruby/compare/v0.17.0...v0.18.0 +[0.17.0]: https://github.com/prettier/plugin-ruby/compare/v0.16.0...v0.17.0 +[0.16.0]: https://github.com/prettier/plugin-ruby/compare/v0.15.1...v0.16.0 +[0.15.1]: https://github.com/prettier/plugin-ruby/compare/v0.15.0...v0.15.1 +[0.15.0]: https://github.com/prettier/plugin-ruby/compare/v0.14.0...v0.15.0 +[0.14.0]: https://github.com/prettier/plugin-ruby/compare/v0.13.0...v0.14.0 +[0.13.0]: https://github.com/prettier/plugin-ruby/compare/v0.12.3...v0.13.0 +[0.12.3]: https://github.com/prettier/plugin-ruby/compare/v0.12.2...v0.12.3 +[0.12.2]: https://github.com/prettier/plugin-ruby/compare/v0.12.1...v0.12.2 +[0.12.1]: https://github.com/prettier/plugin-ruby/compare/v0.12.0...v0.12.1 +[0.12.0]: https://github.com/prettier/plugin-ruby/compare/v0.11.0...v0.12.0 +[0.11.0]: https://github.com/prettier/plugin-ruby/compare/v0.10.0...v0.11.0 [0.10.0]: https://github.com/prettier/plugin-ruby/compare/v0.9.1...v0.10.0 [0.9.1]: https://github.com/prettier/plugin-ruby/compare/v0.9.0...v0.9.1 [0.9.0]: https://github.com/prettier/plugin-ruby/compare/v0.8.0...v0.9.0 diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index d7fd5f1b..06a97449 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -14,22 +14,22 @@ appearance, race, religion, or sexual identity and orientation. Examples of behavior that contributes to creating a positive environment include: -* Using welcoming and inclusive language -* Being respectful of differing viewpoints and experiences -* Gracefully accepting constructive criticism -* Focusing on what is best for the community -* Showing empathy towards other community members +- Using welcoming and inclusive language +- Being respectful of differing viewpoints and experiences +- Gracefully accepting constructive criticism +- Focusing on what is best for the community +- Showing empathy towards other community members Examples of unacceptable behavior by participants include: -* The use of sexualized language or imagery and unwelcome sexual attention or - advances -* Trolling, insulting/derogatory comments, and personal or political attacks -* Public or private harassment -* Publishing others' private information, such as a physical or electronic - address, without explicit permission -* Other conduct which could reasonably be considered inappropriate in a - professional setting +- The use of sexualized language or imagery and unwelcome sexual attention or + advances +- Trolling, insulting/derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or electronic + address, without explicit permission +- Other conduct which could reasonably be considered inappropriate in a + professional setting ## Our Responsibilities diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md deleted file mode 100644 index bc0b0222..00000000 --- a/CONTRIBUTING.md +++ /dev/null @@ -1,141 +0,0 @@ -# Contributing - -Want to contribute? There's a few moving parts that you'll need to know about: - -- Ripper - The Ruby Parser used by this Project -- Prettier - Provides building blocks for formatting documents in a stylistic way -- Testing - Ensuring that there are no formatting or semantic regressions - -Your input Ruby code is parsed by Ripper, and pretty printed using the building blocks provided by Prettier. To ensure there are no regressions, Jest snapshots are used to keep track of the formatting before and after. Additionally there are Ruby tests written with Minitest to ensure there are no semantic regressions after the code has been tidied up. - -## Ripper - -Ripper is the built-in CRuby lexer and parser that understands your Ruby code. It is able to read your source code and provide access to the tokens and the abstract syntax tree associated with your code. - -You can explore Ripper within an interactive Ruby terminal. The process of identifying the tokens within your source code is called lexing: - -```ruby -$ irb -> require 'ripper' - => true -> Ripper.tokenize("puts('hello world')") - => ["puts", "(", "'", "hello world", "'", ")"] -``` - -Once the tokens are understood, Ripper constructs an abstract syntax tree: - -```ruby -$ irb -> require 'ripper' -> pp Ripper.sexp("puts('hello world')") -[:program, - [[:method_add_arg, - [:fcall, [:@ident, "puts", [1, 0]]], - [:arg_paren, - [:args_add_block, - [[:string_literal, - [:string_content, [:@tstring_content, "hello world", [1, 6]]]]], - false]]]]] -``` - -Sometimes it can be useful to view this visually with -[Ripper Preview](https://ripper-preview.herokuapp.com). - -The JavaScript Prettier process spawns a Ruby process within [parse.js](src/parse.js), which interacts with a custom wrapper written around Ripper called RipperJS. By default Ripper discards source code comments from the abstract syntax view. RipperJS attempts to bridge this gap by attaching the original comments to the abstract syntax tree generated by Ripper. Full details are within [ripper.rb](src/ripper.rb) - -If you want to check out the enhanced abstract syntax tree generated by RipperJS: - -``` -bin/sexp file.rb -``` - -Or to view the output on a code snippet: - -``` -bin/sexp "# comment example\nputs('hello world')" -``` - -It's worth noting that there are multiple Ruby parsers available, but for this project Ripper has been chosen for the following reasons: - -- Ripper is the built in reference implementation for CRuby -- Ripper is stable and always provides access to the latest syntax that Ruby supports -- Ripper is written in C, and it's fast - -### Useful links - -- [Ruby's parser](https://github.com/ruby/ruby/blob/trunk/parse.y) - the Ruby parser that will give - you the names of the nodes as well as their structure -- [Ripper test parser events](https://github.com/ruby/ruby/blob/trunk/test/ripper/test_parser_events.rb) - - Ripper test file that gives you code examples of each kind of node -- [How Ripper parses variables](https://rmosolgo.github.io/blog/2018/05/21/how-ripper-parses-variables/) -- [Ripper events](https://rmosolgo.github.io/ripper_events/) -- [Ripper preview](https://ripper-preview.herokuapp.com) - Visualize Ruby's abstract syntax tree - -## Prettier - -[Prettier](https://prettier.io/) provides support for third party plugins by providing access to its -document builders. In plugin-ruby the input Ruby file is parsed with Ripper, then printed with -Prettier. The printing logic for Ruby can be found within [print.js](src/print.js) - -### Useful links - -- [Prettier plugin documentation](https://prettier.io/docs/en/plugins.html) -- [Available commands](https://github.com/prettier/prettier/blob/master/commands.md) -- [Writing a Prettier plugin](https://medium.com/@fvictorio/how-to-write-a-plugin-for-prettier-a0d98c845e70) - -## Testing - -There are two types of testing performed within this project: - -- Visual formatting regressions -- Semantic regressions - -**Formatting regressions** are verified by running the Prettier plugin against a series of -pre-determined [Ruby test cases](test/cases) and saving the the output to a file for later -comparison. If in the future Prettier formats this file differently, the tests will no longer match -the stored snapshot and fail. The JavaScript testing framework Jest provides this functionality. -Rubocop is additionally ran over these files to ensure that they also match the community standards. - -**Semantic regressions** are verified with with Minitest. After formatting the -[Ruby test cases](test/cases) the file is ran with Minitest to ensure that it behaves exactly the -same way before and after formatting has been applied. - -## Useful commands - -After checking out the repo, run `yarn` and `bundle` to install dependencies. - -**Running tests** - -``` -yarn run test -``` - -**Updating Jest snapshots** - -``` -yarn run test -u -``` - -**Viewing the output of RipperJS on a file** - -``` -bin/sexp file.rb -``` - -**Viewing the output of RipperJS on code** - -``` -bin/sexp 'your_ruby_code(1, 2, 3)' -``` - -**Viewing the output of Prettier on a file** - -``` -bin/print file.rb -``` - -**Viewing the output of Prettier on code** - -``` -bin/print 'your_ruby_code(1, 2, 3)' -``` diff --git a/Gemfile b/Gemfile index 4b61218b..be173b20 100644 --- a/Gemfile +++ b/Gemfile @@ -1,8 +1,5 @@ # frozen_string_literal: true -source 'https://rubygems.org' - -gem 'minitest' -gem 'rubocop' +source "https://rubygems.org" gemspec diff --git a/Gemfile.lock b/Gemfile.lock deleted file mode 100644 index f89ec722..00000000 --- a/Gemfile.lock +++ /dev/null @@ -1,40 +0,0 @@ -PATH - remote: . - specs: - prettier (0.10.0) - -GEM - remote: https://rubygems.org/ - specs: - ast (2.4.0) - jaro_winkler (1.5.2) - minitest (5.11.3) - parallel (1.13.0) - parser (2.6.0.0) - ast (~> 2.4.0) - powerpack (0.1.2) - rainbow (3.0.0) - rake (12.3.2) - rubocop (0.63.1) - jaro_winkler (~> 1.5.1) - parallel (~> 1.10) - parser (>= 2.5, != 2.5.1.1) - powerpack (~> 0.1) - rainbow (>= 2.2.2, < 4.0) - ruby-progressbar (~> 1.7) - unicode-display_width (~> 1.4.0) - ruby-progressbar (1.10.0) - unicode-display_width (1.4.1) - -PLATFORMS - ruby - -DEPENDENCIES - bundler (~> 2.0) - minitest - prettier! - rake (~> 12.3) - rubocop - -BUNDLED WITH - 2.0.1 diff --git a/LICENSE b/LICENSE index 2a21a471..1d229424 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2019 Kevin Deisz +Copyright (c) 2019-present Kevin Newton Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index d8146a98..a0db67ff 100644 --- a/README.md +++ b/README.md @@ -8,8 +8,8 @@ Gitter - - Travis + + GitHub Actions NPM Version @@ -22,12 +22,11 @@

-`@prettier/plugin-ruby` is a [prettier](https://prettier.io/) plugin for the Ruby programming language. `prettier` is an opinionated code formatter that supports multiple languages and integrates with most editors. The idea is to eliminate discussions of style in code review and allow developers to get back to thinking about code design instead. - -Under the hood `@prettier/plugin-ruby` uses Ruby's own `ripper` library which allows this package to maintain parity with the existing Ruby parser. `@prettier/plugin-ruby` supports Ruby versions `2.5`, `2.6`, and `trunk`. +`@prettier/plugin-ruby` is a [prettier](https://prettier.io/) plugin for the Ruby programming language and its ecosystem. `prettier` is an opinionated code formatter that supports multiple languages and integrates with most editors. The idea is to eliminate discussions of style in code review and allow developers to get back to thinking about code design instead. For example, the below [code segment](http://www.rubyinside.com/advent2006/4-ruby-obfuscation.html): + ```ruby d=[30644250780,9003106878, 30636278846,66641217692,4501790980, @@ -48,103 +47,155 @@ when run through `@prettier/plugin-ruby` will generate: ```ruby d = [ - 30644250780, - 9003106878, - 30636278846, - 66641217692, - 4501790980, + 30_644_250_780, + 9_003_106_878, + 30_636_278_846, + 66_641_217_692, + 4_501_790_980, 671_24_603036, 131_61973916, 66_606629_920, - 30642677916, - 30643069058 + 30_642_677_916, + 30_643_069_058 ] a, s = [], $*[0] -s.each_byte { |b| a << ('%036b' % d[b.chr.to_i]).scan(/\d{6}/) } +s.each_byte { |b| a << ("%036b" % d[b.chr.to_i]).scan(/\d{6}/) } a.transpose.each do |a| - a.join.each_byte { |i| print i == 49 ? ($*[1] || '#') : 32.chr } + a.join.each_byte { |i| print i == 49 ? ($*[1] || "#") : 32.chr } puts end ``` ## Getting started -First, your system on which you're running is going to need a couple of things: +The `@prettier/plugin-ruby` plugin for `prettier` is a small wrapper around the [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree) gem that provides a Ruby formatter for `prettier`. It does this by keeping a Ruby server running in that background that `prettier` can communicate with when it needs to format a Ruby file. This means that in order to function, you will need to have both the requisite `node` and `ruby` dependencies installed. Because of this configuration, there are a couple of ways that you can get setup to use this plugin. -- [`ruby`](https://www.ruby-lang.org/en/documentation/installation/) `2.5` or newer - there are a lot of ways to install `ruby`, but I recommend [`rbenv`](https://github.com/rbenv/rbenv) -- [`node`](https://nodejs.org/en/download/) `8.3` or newer - `prettier` is a JavaScript package, so you're going to need to install `node` to work with it -- [`npm`](https://www.npmjs.com/get-npm) or [`yarn`](https://yarnpkg.com/en/docs/getting-started) - these are package managers for JavaScript, either one will do +- If you're already using `prettier` in your project to format other files in your project and want to install this as a plugin, you can install it using `npm`. +- If you're not using `prettier` yet in your project, then we recommend using the [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree) gem directly instead of using this plugin. +- Note that this plugin also ships a gem named `prettier` which is a wrapper around the `prettier` CLI and includes this plugin by default, but _we no longer recommend its use_. If you're using that gem, you should migrate to using [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree) instead. -Second, you're going to need to list `@prettier/plugin-ruby` as a JavaScript dependency from within whatever project on which you're working. +To run `prettier` with the Ruby plugin as an `npm` package, you're going to need [`ruby`](https://www.ruby-lang.org/en/documentation/installation/) (version `2.7` or newer) and [`node`](https://nodejs.org/en/download/) (version `16` or newer). -If you do not already have a `package.json` file in the root of your repository, you can create one with: +If you're using the `npm` CLI, then add the plugin by: ```bash -echo '{ "name": "My Project" }' > package.json +npm install --save-dev prettier @prettier/plugin-ruby ``` -After that you can add `prettier` and `@prettier/plugin-ruby` to your `package.json`'s `devDependencies` by running `npm install --save-dev prettier @prettier/plugin-ruby` if you are using `npm` or `yarn add --dev prettier @prettier/plugin-ruby` if you are using `yarn`. +Or if you're using `yarn`, then add the plugin by: + +```bash +yarn add --dev prettier @prettier/plugin-ruby +``` -Now, you can run `prettier` to tidy up your `ruby` files! Verify by running against one single file: +You'll also need to add the necessary Ruby dependencies. You can do this by running: ```bash -./node_modules/.bin/prettier --write path/to/file.rb +gem install bundler prettier_print syntax_tree syntax_tree-haml syntax_tree-rbs ``` -If you're happy, you can can run `prettier` on an entire codebase: +The `prettier` executable is now installed and ready for use: ```bash -./node_modules/.bin/prettier --write '**/*.{rb,rake}' +./node_modules/.bin/prettier --plugin=@prettier/plugin-ruby --write '**/*' ``` -Note that you can also install `prettier` globally with `npm install -g prettier` or you can add `./node_modules/.bin` to your `$PATH` so you don't need to reference the executable from the directory each time. +### Using Prettier >= 3.0 + +You need to tell Prettier to use the plugin, add the following to your existing [prettier configuration +file](https://prettier.io/docs/en/configuration.html). + +```json +{ + "plugins": ["@prettier/plugin-ruby"] +} +``` ## Configuration -Below are the options (from [`src/ruby.js`](src/ruby.js)) that `@prettier/plugin-ruby` currently supports: +Below are the options (from [`src/plugin.js`](src/plugin.js)) that `@prettier/plugin-ruby` currently supports: -| Name | Default | Description | -| -------------------- | :-----: | ------------------------------------------------------------------------------------------------------------- | -| `printWidth` | `80` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#print-width)). | -| `requirePragma` | `false` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#require-pragma)). | -| `tabWidth` | `2` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#tab-width)). | -| `addTrailingCommas` | `false` | Adds a trailing comma to array literals, hash literals, and method calls. | -| `inlineConditionals` | `true` | When it fits on one line, allows if and unless statements to use the modifier form. | -| `inlineLoops` | `true` | When it fits on one line, allows while and until statements to use the modifier form. | -| `preferHashLabels` | `true` | When possible, uses the shortened hash key syntax, as opposed to hash rockets. | -| `preferSingleQuotes` | `true` | When double quotes are not necessary for interpolation, prefers the use of single quotes for string literals. | +| API Option | CLI Option | Default | Description | +| -------------------- | --------------------- | :------------------------------------------------: | --------------------------------------------------------------------------------------------------------------------------------------------------- | +| `printWidth` | `--print-width` | `80` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#print-width)). | +| `requirePragma` | `--require-pragma` | `false` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#require-pragma)). | +| `rubyExecutablePath` | `"ruby"` | Allows you to configure your Ruby executable path. | +| `rubyPlugins` | `--ruby-plugins` | `""` | The comma-separated list of plugins to require. See [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree#plugins). | +| `rubySingleQuote` | `--ruby-single-quote` | `false` | Whether or not to default to single quotes for Ruby code. See [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree#plugins). | +| `tabWidth` | `--tab-width` | `2` | Same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#tab-width)). | +| `trailingComma` | `--trailing-comma` | `es5` | Almost same as in Prettier ([see prettier docs](https://prettier.io/docs/en/options.html#trailing-commas)). Will be on for any value except `none`. | Any of these can be added to your existing [prettier configuration file](https://prettier.io/docs/en/configuration.html). For example: ```json { - "preferSingleQuotes": false + "tabWidth": 4 } ``` Or, they can be passed to `prettier` as arguments: ```bash -./node_modules/.bin/prettier --prefer-single-quotes false --write '**/*.{rb,rake}' +bundle exec rbprettier --tab-width 4 --write '**/*' ``` -## Contributing +### Ignoring code -Check out our [contributing guide](CONTRIBUTING.md). Bug reports and pull requests are welcome on GitHub at https://github.com/prettier/plugin-ruby. +Sometimes you want to leave your formatting in place and have `prettier` not format it, but continue to format the rest of the file. `prettier` has the ability to do this with `prettier-ignore` comments, but because the underlying formatter for this plugin is [Syntax Tree](https://github.com/ruby-syntax-tree/syntax_tree), you instead would use a `stree-ignore` comment. -## License +### Usage with RuboCop -The package is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT). +RuboCop and Prettier for Ruby serve different purposes, but there is overlap with some of RuboCop's functionality. Prettier provides a RuboCop configuration file to disable the rules which would clash. To enable this file, add the following configuration at the top of your project's `.rubocop.yml`: -## Contributors +```yaml +inherit_from: + - node_modules/@prettier/plugin-ruby/rubocop.yml +``` -Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)): +### Usage with an editor - - -
Kevin Deisz
Kevin Deisz

💻 📖 🚧 👀 ⚠️
Alan Foster
Alan Foster

💻 📖 👀 ⚠️
johnschoeman
johnschoeman

⚠️
Aaron Jensen
Aaron Jensen

📖
Cameron Bothner
Cameron Bothner

💻
+For [supported editor integrations](https://github.com/prettier/prettier/blob/main/website/data/editors.yml), you should follow the instructions for installing the integration, then install the npm version of this plugin as a development dependency of your project. For most integrations, that should be sufficient. For convenience, the instructions for integrating with VSCode are used as an example below: - +- Install the [Prettier - Code Formatter](https://github.com/prettier/prettier-vscode) extension. +- Add the npm `@prettier/plugin-ruby` package to your project as described above. +- Configure in your `settings.json` (`formatOnSave` is optional): -This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome! +```json +{ + "[ruby]": { + "editor.defaultFormatter": "esbenp.prettier-vscode", + "editor.formatOnSave": true + } +} +``` + +Refer to [this issue](https://github.com/prettier/plugin-ruby/issues/113#issuecomment-783426539) if you're having difficulties. + +## Contributing + +Thanks so much for your interest in contributing! You can contribute in many ways, including: + +- Contributing code to fix any bugs on [GitHub](https://github.com/prettier/plugin-ruby). +- Reporting issues on [GitHub](https://github.com/prettier/plugin-ruby/issues/new). +- Supporting `prettier/plugin-ruby` on [OpenCollective](https://opencollective.com/prettier-ruby/contribute). Your organization's logo will show up here with a link to your website. + + + + + + + + + + + + + + + + + +## License + +The package is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT). diff --git a/Rakefile b/Rakefile index 4caa98e2..a4eb3b0f 100644 --- a/Rakefile +++ b/Rakefile @@ -1,12 +1,12 @@ # frozen_string_literal: true -require 'bundler/gem_tasks' -require 'rake/testtask' +require "bundler/gem_tasks" +require "rake/testtask" Rake::TestTask.new(:test) do |t| - t.libs << 'test' - t.libs << 'lib' - t.test_files = FileList['test/**/*_test.rb'] + t.libs << "test/rb" + t.libs << "lib" + t.test_files = FileList["test/rb/**/*_test.rb"] end task default: :test diff --git a/bin/ci-install b/bin/ci-install deleted file mode 100755 index 833ad9a7..00000000 --- a/bin/ci-install +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env bash - -set -euxo pipefail - -gem update --system -gem install bundler - -source ~/.nvm/nvm.sh -nvm install 10 -nvm use 10 - -yarn --ignore-engines install diff --git a/bin/console b/bin/console deleted file mode 100755 index 5d2f5a89..00000000 --- a/bin/console +++ /dev/null @@ -1,7 +0,0 @@ -#!/usr/bin/env ruby - -require 'bundler/setup' -require 'prettier' - -require 'irb' -IRB.start(__FILE__) diff --git a/bin/has-pragma b/bin/has-pragma deleted file mode 100755 index 26c0c235..00000000 --- a/bin/has-pragma +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env node - -const fs = require("fs"); -const { hasPragma } = require("../src/ruby").parsers.ruby; - -console.log(hasPragma(fs.readFileSync(process.argv[2], "utf-8"))); diff --git a/bin/print b/bin/print deleted file mode 100755 index b7cbb645..00000000 --- a/bin/print +++ /dev/null @@ -1,10 +0,0 @@ -#!/usr/bin/env node - -const fs = require("fs"); -const prettier = require("prettier"); - -const code = fs.existsSync(process.argv[2]) - ? fs.readFileSync(process.argv[2], "utf-8") - : process.argv.slice(2).join(" ").replace(/\\n/g, "\n"); - -console.log(prettier.format(code, { parser: "ruby", plugins: ["."] })); diff --git a/bin/print.js b/bin/print.js new file mode 100755 index 00000000..51a3d1e9 --- /dev/null +++ b/bin/print.js @@ -0,0 +1,31 @@ +#!/usr/bin/env node + +import { existsSync, readFileSync } from "fs"; +import { formatWithCursor } from "prettier"; + +import plugin from "../src/plugin.js"; + +let parser = "ruby"; +let contentIdx = 2; + +if (["rbs", "haml"].includes(process.argv[contentIdx])) { + parser = process.argv[contentIdx]; + contentIdx += 1; +} + +let content; + +if (existsSync(process.argv[contentIdx])) { + content = readFileSync(process.argv[contentIdx], "utf-8"); +} else if (process.argv.length === contentIdx) { + const extension = parser === "ruby" ? "rb" : parser; + content = readFileSync(`test.${extension}`, "utf-8"); +} else { + content = process.argv.slice(contentIdx).join(" ").replace(/\\n/g, "\n"); +} + +formatWithCursor(content, { + parser, + plugins: [plugin], + cursorOffset: 1 +}).then(({ formatted }) => console.log(formatted)); diff --git a/bin/sexp b/bin/sexp deleted file mode 100755 index e83e2e90..00000000 --- a/bin/sexp +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env ruby - -require File.expand_path(File.join('..', 'src', 'ripper.rb'), __dir__) - -source = File.file?(ARGV[0]) ? File.read(ARGV[0]) : ARGV[0].gsub('\\n', "\n") -pp RipperJS.new(source).parse diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 00000000..5f507d16 --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,21 @@ +import eslintJs from "@eslint/js"; +import eslintConfigPrettier from "eslint-config-prettier"; +import globals from "globals"; + +export default [ + eslintJs.configs.recommended, + eslintConfigPrettier, + { + languageOptions: { + globals: { + ...globals.builtin, + ...globals.jest, + ...globals.node + } + }, + rules: { + "no-unused-vars": "off" + } + }, + { ignores: ["coverage"] } +]; diff --git a/exe/rbprettier b/exe/rbprettier index a5b550e0..f5b653a3 100755 --- a/exe/rbprettier +++ b/exe/rbprettier @@ -1,8 +1,7 @@ #!/usr/bin/env ruby # frozen_string_literal: true -$:.unshift(File.expand_path(File.join('..', 'lib'), __dir__)) -require 'prettier' +$:.unshift(File.expand_path(File.join("..", "lib"), __dir__)) +require "prettier" -Prettier.run(ARGV) -exit($?.exitstatus) if $?.exited? +exit(Prettier.run(ARGV)) diff --git a/lib/prettier.rb b/lib/prettier.rb index 7e68c8c2..fa68dceb 100644 --- a/lib/prettier.rb +++ b/lib/prettier.rb @@ -1,33 +1,53 @@ # frozen_string_literal: true +require "json" unless defined?(JSON) +require "open3" + module Prettier - require 'json' unless defined?(JSON) - package = JSON.parse(File.read(File.join(__dir__, '..', 'package.json'))) + directory = -File.expand_path("..", __dir__) + package = File.read(File.join(directory, "package.json")) - VERSION = package['version'] + PLUGIN = -File.join(directory, "src/plugin.js") + BINARY = -File.join(directory, "node_modules/prettier/bin/prettier.cjs") + VERSION = -JSON.parse(package)["version"] - class << self - def run(args) - prettier = File.expand_path(File.join('..', 'pkg', target), __dir__) - plugin = File.expand_path(File.join('..'), __dir__) - quoted = args.map { |arg| arg.start_with?('-') ? arg : "'#{arg}'" } + def self.run(args) + quoted = args.map { |arg| arg.start_with?("-") ? arg : "\"#{arg}\"" } + command = "node #{BINARY} --plugin \"#{PLUGIN}\" #{quoted.join(" ")}" + opts = STDIN.tty? ? {} : { stdin_data: STDIN } - system "#{prettier} --plugin '#{plugin}' #{quoted.join(' ')}" - end + stdout, stderr, status = Open3.capture3({}, command, opts) + STDOUT.puts(stdout) + + # If we completed successfully, then just exit out. + exitstatus = status.exitstatus + return exitstatus if exitstatus == 0 - private - - def target - case RUBY_PLATFORM - when /darwin/ - 'prettier-macos' - when /linux/ - 'prettier-linux' - when /win32/ - 'prettier-win.exe' - else - raise "Unsupported platform #{RUBY_PLATFORM}" - end + if stderr.match?(%r{Cannot find module '/.+?/bin-prettier.js'}) + # If we're missing bin-prettier.js, then it's possible the user installed + # the gem through git, which wouldn't have installed the requisite + # JavaScript files. + STDERR.puts(<<~MSG) + Could not find the JavaScript files necessary to run prettier. + + If you installed this dependency through git instead of from rubygems, + it does not install the necessary files by default. To fix this you can + either install them yourself by cd-ing into the directory where this gem + is located (#{File.expand_path("..", __dir__)}) and running: + + `yarn install` + or + `npm install` + or + you can change the source in your Gemfile to point directly to rubygems. + MSG + else + # Otherwise, just print out the same error that prettier emitted, as it's + # unknown to us. + STDERR.puts(stderr) end + + # Make sure we still exit with the same status code the prettier emitted. + exitstatus end end diff --git a/lib/prettier/rake/task.rb b/lib/prettier/rake/task.rb index 63856fd6..0da0fc9e 100644 --- a/lib/prettier/rake/task.rb +++ b/lib/prettier/rake/task.rb @@ -1,7 +1,7 @@ # frozen_string_literal: true -require 'rake' -require 'rake/tasklib' +require "rake" +require "rake/tasklib" module Prettier module Rake @@ -35,7 +35,7 @@ class Task < ::Rake::TaskLib def initialize(name = :prettier) @name = name @write = true - @source_files = 'lib/**/*.rb' + @source_files = "lib/**/*.rb" yield self if block_given? define_task @@ -44,13 +44,13 @@ def initialize(name = :prettier) private def define_task - desc 'Runs prettier over source files' + desc "Runs prettier over source files" task(name) { run_task } end def run_task - Prettier.run([('--write' if write), source_files].compact) - exit($?.exitstatus) if $?.exited? + Prettier.run([write ? "--write" : "--check", source_files].compact) + exit($?.exitstatus) if $?&.exited? end end end diff --git a/package.json b/package.json index b6fa087d..69dea870 100644 --- a/package.json +++ b/package.json @@ -1,40 +1,55 @@ { "name": "@prettier/plugin-ruby", - "version": "0.10.0", + "version": "4.0.4", "description": "prettier plugin for the Ruby programming language", - "main": "src/ruby.js", + "type": "module", + "main": "src/plugin.js", "scripts": { - "build": "pkg --output pkg/prettier --targets=linux,macos,win node_modules/prettier/bin-prettier.js", - "lint": "eslint .", - "print": "prettier --plugin=.", - "rubocop": "run() { prettier --plugin=. $@ | bundle exec rubocop --stdin $1; }; run", - "test": "jest" + "checkFormat": "prettier . --check", + "lint": "eslint --cache .", + "test": "node --experimental-vm-modules node_modules/jest/bin/jest.js" }, "repository": { "type": "git", "url": "git+https://github.com/prettier/plugin-ruby.git" }, - "author": "Kevin Deisz", + "author": "Kevin Newton", "license": "MIT", "bugs": { "url": "https://github.com/prettier/plugin-ruby/issues" }, "homepage": "https://github.com/prettier/plugin-ruby#readme", - "dependencies": { - "prettier": "^1.16.4" + "peerDependencies": { + "prettier": "^3.0.0" }, "devDependencies": { - "all-contributors-cli": "^6.1.2", - "eslint": "^5.15.0", - "eslint-config-airbnb-base": "^13.1.0", - "eslint-plugin-import": "^2.16.0", - "jest": "^24.0.0", - "pkg": "^4.3.7" + "@eslint/js": "^9.21.0", + "eslint": "^9.21.0", + "eslint-config-prettier": "^10.0.2", + "globals": "^16.0.0", + "husky": "^9.1.7", + "jest": "^29.7.0", + "prettier": "^3.5.3", + "pretty-quick": "^4.1.1" }, "jest": { - "setupFiles": [ - "./test/testRunner.js" + "globalSetup": "./test/js/globalSetup.js", + "globalTeardown": "./test/js/globalTeardown.js", + "setupFilesAfterEnv": [ + "./test/js/setupTests.js" ], - "testRegex": ".test.js$" + "testRegex": ".test.js$", + "transform": {} + }, + "husky": { + "hooks": { + "pre-commit": "pretty-quick --staged" + } + }, + "prettier": { + "trailingComma": "none", + "plugins": [ + "./src/plugin.js" + ] } } diff --git a/prettier.gemspec b/prettier.gemspec index 6750e277..5cc3cf5a 100644 --- a/prettier.gemspec +++ b/prettier.gemspec @@ -1,30 +1,34 @@ # frozen_string_literal: true -require 'json' unless defined?(JSON) -package = JSON.parse(File.read(File.join(__dir__, 'package.json'))) +require "json" unless defined?(JSON) +package = JSON.parse(File.read(File.join(__dir__, "package.json"))) Gem::Specification.new do |spec| - spec.name = 'prettier' - spec.version = package['version'] - spec.authors = [package['author']] + spec.name = "prettier" + spec.version = package.fetch("version") + spec.authors = [package.fetch("author")] - spec.summary = package['description'] - spec.homepage = package['homepage'] - spec.license = package['license'] + spec.summary = package.fetch("description") + spec.homepage = package.fetch("homepage") + spec.license = package.fetch("license") spec.files = - Dir.chdir(File.expand_path('..', __FILE__)) do - `git ls-files -z`.split("\x0").select do |f| - f.match( - /^(bin|exe|src|CHANGELOG.md|package.json|yarn.lock|.rubocop.yml)/ - ) - end + Dir.chdir(__dir__) do + %w[LICENSE package.json rubocop.yml] + Dir["{{exe,lib,src}/**/*,*.md}"] + + Dir["node_modules/prettier/**/*"] end - spec.bindir = 'exe' - spec.executables = 'rbprettier' + spec.required_ruby_version = ">= 2.7.0" + + spec.bindir = "exe" + spec.executables = "rbprettier" spec.require_paths = %w[lib] - spec.add_development_dependency 'bundler', '~> 2.0' - spec.add_development_dependency 'rake', '~> 12.3' + spec.add_dependency "syntax_tree", ">= 4.0.1" + spec.add_dependency "syntax_tree-haml", ">= 2.0.0" + spec.add_dependency "syntax_tree-rbs", ">= 0.2.0" + + spec.add_development_dependency "bundler" + spec.add_development_dependency "minitest" + spec.add_development_dependency "rake" end diff --git a/rubocop.yml b/rubocop.yml new file mode 100644 index 00000000..64316d0c --- /dev/null +++ b/rubocop.yml @@ -0,0 +1,64 @@ +# Disabling all Layout/* rules, as they're unnecessary when the user is using +# Syntax Tree to handle all of the formatting. +Layout: + Enabled: false + +# Re-enable Layout/LineLength because certain cops that most projects use +# (e.g. Style/IfUnlessModifier) require Layout/LineLength to be enabled. +# By leaving it disabled, those rules will mis-fire. +# +# Users can always override these defaults in their own rubocop.yml files. +# https://github.com/prettier/plugin-ruby/issues/825 +Layout/LineLength: + Enabled: true + +Style/MultilineIfModifier: + Enabled: false + +# Syntax Tree will expand empty methods to put the end keyword on the subsequent +# line to reduce git diff noise. +Style/EmptyMethod: + EnforcedStyle: expanded + +# lambdas that are constructed with the lambda method call cannot be safely +# turned into lambda literals without removing a method call. +Style/Lambda: + Enabled: false + +# When method chains with multiple blocks are chained together, rubocop will let +# them pass if they're using braces but not if they're using do and end +# keywords. Because we will break individual blocks down to using keywords if +# they are multiline, this conflicts with rubocop. +Style/MultilineBlockChain: + Enabled: false + +# Disable the single- vs double-quotes rules as these depend on whether the user +# has added or not `plugin/single_quotes` for `syntax_tree` +Style/StringLiterals: + Enabled: false + +Style/StringLiteralsInInterpolation: + Enabled: false + +Style/QuotedSymbols: + Enabled: false + +# We let users have a little more freedom with symbol and words arrays. If the +# user only has an individual item like ["value"] then we don't bother +# converting it because it ends up being just noise. +Style/SymbolArray: + Enabled: false + +Style/WordArray: + Enabled: false + +# Disable the trailing-comma rules as these depend on whether the user has added +# or not `plugin/trailing_comma` for `syntax_tree` +Style/TrailingCommaInArguments: + Enabled: false + +Style/TrailingCommaInArrayLiteral: + Enabled: false + +Style/TrailingCommaInHashLiteral: + Enabled: false diff --git a/src/escapePattern.js b/src/escapePattern.js deleted file mode 100644 index 46a71b31..00000000 --- a/src/escapePattern.js +++ /dev/null @@ -1,45 +0,0 @@ -/** - * String literal syntax documentation from Ruby source (2.7.0-dev) - * - * Double-quote strings allow escaped characters such as \n for - * newline, \t for tab, etc. The full list of supported escape - * sequences are as follows: - * - * \a bell, ASCII 07h (BEL) - * \b backspace, ASCII 08h (BS) - * \t horizontal tab, ASCII 09h (TAB) - * \n newline (line feed), ASCII 0Ah (LF) - * \v vertical tab, ASCII 0Bh (VT) - * \f form feed, ASCII 0Ch (FF) - * \r carriage return, ASCII 0Dh (CR) - * \e escape, ASCII 1Bh (ESC) - * \s space, ASCII 20h (SPC) - * \\ backslash, \ - * \nnn octal bit pattern, where nnn is 1-3 octal digits ([0-7]) - * \xnn hexadecimal bit pattern, where nn is 1-2 hexadecimal digits ([0-9a-fA-F]) - * \unnnn Unicode character, where nnnn is exactly 4 hexadecimal digits ([0-9a-fA-F]) - * \u{nnnn ...} Unicode character(s), where each nnnn is 1-6 hexadecimal digits ([0-9a-fA-F]) - * \cx or \C-x control character, where x is an ASCII printable character - * \M-x meta character, where x is an ASCII printable character - * \M-\C-x meta control character, where x is an ASCII printable character - * \M-\cx same as above - * \c\M-x same as above - * \c? or \C-? delete, ASCII 7Fh (DEL) - * - * In addition to disabling interpolation, single-quoted strings also disable all - * escape sequences except for the single-quote (\') and backslash - * (\\\\). - */ -const patterns = [ - "[abtnvfres\\\\]", // simple - "[0-7]{1,3}", // octal bits - "x[0-9a-fA-F]{1,2}", // hex bit - "u[0-9a-fA-F]{4}", // unicode char - "u\\{[0-9a-fA-F ]+\\}", // unicode chars - "c[ -~]|C\\-[ -~]", // control - "M\\-[ -~]", // meta - "M\\-\\\\C\\-[ -~]|M\\-\\\\c[ -~]|c\\\\M\\-[ -~]", // meta control - "c\\?|C\\-\\?" // delete -]; - -module.exports = new RegExp(`\\\\(${patterns.join("|")})`); diff --git a/src/nodes.js b/src/nodes.js deleted file mode 100644 index 143a3d80..00000000 --- a/src/nodes.js +++ /dev/null @@ -1,606 +0,0 @@ -const { align, breakParent, concat, dedent, group, hardline, ifBreak, indent, join, line, literalline, markAsRoot, softline, trim } = require("prettier").doc.builders; -const { removeLines } = require("prettier").doc.utils; -const { concatBody, empty, first, literal, makeArgs, makeCall, makeList, prefix, printComments, skipAssignIndent } = require("./utils"); - -const nodes = { - "@int": (path, _opts, _print) => { - const { body } = path.getValue(); - return /^0[0-9]/.test(body) ? `0o${body.slice(1)}` : body; - }, - "@__end__": (path, _opts, _print) => { - const { body } = path.getValue(); - return concat([trim, "__END__", literalline, body]); - }, - arg_paren: (path, opts, print) => { - if (path.getValue().body[0] === null) { - return ""; - } - - const { addTrailingCommas } = opts; - const { args, heredocs } = makeArgs(path, opts, print, 0); - - const argsNode = path.getValue().body[0]; - const hasBlock = argsNode.type === "args_add_block" && argsNode.body[1]; - - if (heredocs.length > 1) { - return concat(["(", join(", ", args), ")"].concat(heredocs)); - } - - const parenDoc = group(concat([ - "(", - indent(concat([ - softline, - join(concat([",", line]), args), - addTrailingCommas && !hasBlock ? ifBreak(",", "") : "" - ])), - concat([softline, ")"]) - ])); - - if (heredocs.length === 1) { - return group(concat([parenDoc].concat(heredocs))); - } - - return parenDoc; - }, - args: makeList, - args_add_block: (path, opts, print) => { - const parts = path.call(print, "body", 0); - - if (path.getValue().body[1]) { - parts.push(concat(["&", path.call(print, "body", 1)])); - } - - return parts; - }, - args_add_star: (path, opts, print) => { - const printed = path.map(print, "body"); - const parts = printed[0].concat([concat(["*", printed[1]])]).concat(printed.slice(2)); - - return parts; - }, - assoc_new: (path, { preferHashLabels }, print) => { - const parts = []; - const [printedLabel, printedValue] = path.map(print, "body"); - - switch (path.getValue().body[0].type) { - case "@label": - if (preferHashLabels) { - parts.push(printedLabel); - } else { - parts.push(`:${printedLabel.slice(0, printedLabel.length - 1)} =>`); - } - break; - case "symbol_literal": - if (preferHashLabels && path.getValue().body[0].body.length === 1) { - const { comments, start } = path.getValue().body[0]; - const node = concat([path.call(print, "body", 0, "body", 0, "body", 0), ":"]); - - if (comments) { - parts.push(printComments(node, start, comments)); - } else { - parts.push(node); - } - } else { - parts.push(concat([printedLabel, " =>"])); - } - break; - default: - parts.push(concat([printedLabel, " =>"])); - break; - } - - if (skipAssignIndent(path.getValue().body[1])) { - parts.push(" ", printedValue); - } else { - parts.push(indent(concat([line, printedValue]))); - } - - return group(concat(parts)); - }, - assoc_splat: prefix("**"), - assoclist_from_args: (path, opts, print) => group(join( - concat([",", line]), - path.map(print, "body", 0) - )), - assign: (path, opts, print) => { - const [printedTarget, printedValue] = path.map(print, "body"); - let adjustedValue = printedValue; - - if (["mrhs_add_star", "mrhs_new_from_args"].includes(path.getValue().body[1].type)) { - adjustedValue = group(join(concat([",", line]), printedValue)); - } - - if (skipAssignIndent(path.getValue().body[1])) { - return group(concat([printedTarget, " = ", adjustedValue])); - } - - return group(concat([ - printedTarget, - " =", - indent(concat([line, adjustedValue])) - ])); - }, - assign_error: (_path, _opts, _print) => { - throw new Error("Can't set variable"); - }, - bare_assoc_hash: (path, opts, print) => group( - join(concat([",", line]), path.map(print, "body", 0)) - ), - begin: (path, opts, print) => group(concat([ - "begin", - indent(concat([hardline, concat(path.map(print, "body"))])), - group(concat([hardline, "end"])) - ])), - binary: (path, opts, print) => { - const operator = path.getValue().body[1]; - const useNoSpace = operator === "**"; - - return group(concat([ - concat([path.call(print, "body", 0), useNoSpace ? "" : " "]), - operator, - indent(concat([useNoSpace ? softline : line, path.call(print, "body", 2)])) - ])); - }, - block_var: (path, opts, print) => { - const parts = ["|", removeLines(path.call(print, "body", 0))]; - - // The second part of this node is a list of optional block-local variables - if (path.getValue().body[1]) { - parts.push("; ", join(", ", path.map(print, "body", 1))); - } - - parts.push("| "); - return concat(parts); - }, - blockarg: (path, opts, print) => concat(["&", path.call(print, "body", 0)]), - bodystmt: (path, opts, print) => { - const [_statements, rescue, elseClause, ensure] = path.getValue().body; - const parts = [path.call(print, "body", 0)]; - - if (rescue) { - parts.push(dedent(concat([hardline, path.call(print, "body", 1)]))); - } - - if (elseClause) { - // Before Ruby 2.6, this piece of bodystmt was an explicit "else" node - const stmts = elseClause.type === "else" ? path.call(print, "body", 2, "body", 0) : path.call(print, "body", 2); - - parts.push(concat([dedent(concat([hardline, "else"])), hardline, stmts])); - } - - if (ensure) { - parts.push(dedent(concat([hardline, path.call(print, "body", 3)]))); - } - - return group(concat(parts)); - }, - break: (path, opts, print) => { - const content = path.getValue().body[0]; - - if (content.body.length === 0) { - return "break"; - } - - if (content.body[0].body[0].type === "paren") { - return concat(["break ", path.call(print, "body", 0, "body", 0, "body", 0, "body", 0)]); - } - - return concat(["break ", join(", ", path.call(print, "body", 0))]); - }, - case: (path, opts, print) => { - const parts = ["case "]; - - if (path.getValue().body[0]) { - parts.push(path.call(print, "body", 0)); - } - - parts.push( - group(concat([hardline, path.call(print, "body", 1)])), - group(concat([hardline, "end"])) - ); - - return group(concat(parts)); - }, - class: (path, opts, print) => { - const [_constant, superclass, statements] = path.getValue().body; - - const parts = ["class ", path.call(print, "body", 0)]; - if (superclass) { - parts.push(" < ", path.call(print, "body", 1)); - } - - // If the body is empty, we can replace with a ; - const stmts = statements.body[0].body; - if (stmts.length === 1 && stmts[0].type === "void_stmt") { - return group(concat([concat(parts), ifBreak(line, "; "), "end"])); - } - - return group(concat([ - concat(parts), - indent(concat([hardline, path.call(print, "body", 2)])), - concat([hardline, "end"]) - ])); - }, - class_name_error: (_path, _opts, _print) => { - throw new Error("class/module name must be CONSTANT"); - }, - const_path_field: (path, opts, print) => join("::", path.map(print, "body")), - const_path_ref: (path, opts, print) => join("::", path.map(print, "body")), - const_ref: first, - defined: (path, opts, print) => group(concat([ - "defined?(", - indent(concat([softline, path.call(print, "body", 0)])), - concat([softline, ")"]) - ])), - dot2: (path, opts, print) => concat([ - path.call(print, "body", 0), - "..", - path.getValue().body[1] ? path.call(print, "body", 1) : "" - ]), - dot3: (path, opts, print) => concat([ - path.call(print, "body", 0), - "...", - path.getValue().body[1] ? path.call(print, "body", 1) : "" - ]), - dyna_symbol: (path, opts, print) => { - const { quote } = path.getValue().body[0]; - - return concat([`:${quote}`, concat(path.call(print, "body", 0)), quote]); - }, - else: (path, opts, print) => { - const stmts = path.getValue().body[0]; - - return concat([ - stmts.body.length === 1 && stmts.body[0].type === "command" ? breakParent : "", - "else", - indent(concat([softline, path.call(print, "body", 0)])) - ]); - }, - embdoc: (path, _opts, _print) => concat([trim, path.getValue().body]), - ensure: (path, opts, print) => group(concat([ - "ensure", - indent(concat([hardline, concat(path.map(print, "body"))])) - ])), - excessed_comma: empty, - fcall: concatBody, - field: (path, opts, print) => group(concat([ - path.call(print, "body", 0), - concat([makeCall(path, opts, print), path.call(print, "body", 2)]) - ])), - hash: (path, { addTrailingCommas }, print) => { - if (path.getValue().body[0] === null) { - return "{}"; - } - - return group(concat([ - "{", - indent(concat([ - line, - concat(path.map(print, "body")), - addTrailingCommas ? ifBreak(",", "") : "" - ])), - concat([line, "}"]) - ])); - }, - lambda: (path, opts, print) => { - let params = path.getValue().body[0]; - let paramsConcat = ""; - - if (params.type === "params") { - paramsConcat = path.call(print, "body", 0); - } else { - ([params] = params.body); - paramsConcat = path.call(print, "body", 0, "body", 0); - } - - const noParams = params.body.every(type => !type); - const commandNode = path.getParentNode(2); - - const inlineLambda = concat([ - "->", - noParams ? "" : concat(["(", paramsConcat, ")"]), - " { ", - path.call(print, "body", 1), - " }" - ]); - - if (commandNode && ["command", "command_call"].includes(commandNode.type)) { - return group(ifBreak( - concat([ - "lambda {", - noParams ? "" : concat([" |", removeLines(paramsConcat), "|"]), - indent(concat([line, path.call(print, "body", 1)])), - concat([line, "}"]) - ]), - inlineLambda - )); - } - - return group(ifBreak( - concat([ - "lambda do", - noParams ? "" : concat([" |", removeLines(paramsConcat), "|"]), - indent(concat([softline, path.call(print, "body", 1)])), - concat([softline, "end"]) - ]), - inlineLambda - )); - }, - massign: (path, opts, print) => { - let right = path.call(print, "body", 1); - - if (["mrhs_add_star", "mrhs_new_from_args"].includes(path.getValue().body[1].type)) { - right = group(join(concat([",", line]), right)); - } - - return group(concat([ - group(join(concat([",", line]), path.call(print, "body", 0))), - " =", - indent(concat([line, right])) - ])); - }, - method_add_arg: concatBody, - method_add_block: concatBody, - methref: (path, opts, print) => join(".:", path.map(print, "body")), - mlhs: makeList, - mlhs_add_post: (path, opts, print) => ( - path.call(print, "body", 0).concat(path.call(print, "body", 1)) - ), - mlhs_add_star: (path, opts, print) => ( - path.call(print, "body", 0).concat([ - path.getValue().body[1] ? concat(["*", path.call(print, "body", 1)]) : "*" - ]) - ), - mlhs_paren: (path, opts, print) => { - if (["massign", "mlhs_paren"].includes(path.getParentNode().type)) { - // If we're nested in brackets as part of the left hand side of an - // assignment, i.e., (a, b, c) = 1, 2, 3 - // ignore the current node and just go straight to the content - return path.call(print, "body", 0); - } - - return group(concat([ - "(", - indent(concat([softline, join(concat([",", line]), path.call(print, "body", 0))])), - concat([softline, ")"]) - ])); - }, - mrhs: makeList, - mrhs_add_star: (path, opts, print) => ( - path.call(print, "body", 0).concat([concat(["*", path.call(print, "body", 1)])]) - ), - mrhs_new_from_args: (path, opts, print) => { - const parts = path.call(print, "body", 0); - - if (path.getValue().body.length > 1) { - parts.push(path.call(print, "body", 1)); - } - - return parts; - }, - module: (path, opts, print) => { - const declaration = group(concat(["module ", path.call(print, "body", 0)])); - - // If the body is empty, we can replace with a ; - const stmts = path.getValue().body[1].body[0].body; - if (stmts.length === 1 && stmts[0].type === "void_stmt") { - return group(concat([declaration, ifBreak(line, "; "), "end"])); - } - - return group(concat([ - declaration, - indent(concat([hardline, path.call(print, "body", 1)])), - concat([hardline, "end"]) - ])); - }, - next: (path, opts, print) => { - const args = path.getValue().body[0].body[0]; - - if (!args) { - return "next"; - } - - if (args.body[0].type === "paren") { - // Ignoring the parens node and just going straight to the content - return concat(["next ", path.call(print, "body", 0, "body", 0, "body", 0, "body", 0)]); - } - - return concat(["next ", join(", ", path.call(print, "body", 0))]); - }, - number_arg: first, - opassign: (path, opts, print) => group(concat([ - path.call(print, "body", 0), - " ", - path.call(print, "body", 1), - indent(concat([line, path.call(print, "body", 2)])) - ])), - paren: (path, opts, print) => { - if (!path.getValue().body[0]) { - return "()"; - } - - let content = path.call(print, "body", 0); - - if (["args", "args_add_star", "args_add_block"].includes(path.getValue().body[0].type)) { - content = join(concat([",", line]), content); - } - - return group(concat([ - "(", - indent(concat([softline, content])), - concat([softline, ")"]) - ])); - }, - program: (path, opts, print) => markAsRoot(concat([ - join(literalline, path.map(print, "body")), - literalline - ])), - redo: literal("redo"), - rescue: (path, opts, print) => { - const [exception, variable, _statements, addition] = path.getValue().body; - const parts = ["rescue"]; - - if (exception || variable) { - if (exception) { - if (Array.isArray(exception)) { - parts.push(" ", path.call(print, "body", 0, 0)); - } else { - parts.push( - " ", - align("rescue ".length, group(join(concat([",", line]), path.call(print, "body", 0)))) - ); - } - } - - if (variable) { - parts.push(group(concat([" => ", path.call(print, "body", 1)]))); - } - } else { - parts.push(" StandardError"); - } - - parts.push(indent(concat([hardline, path.call(print, "body", 2)]))); - - if (addition) { - parts.push(concat([hardline, path.call(print, "body", 3)])); - } - - return group(concat(parts)); - }, - rescue_mod: (path, opts, print) => group(concat([ - "begin", - indent(concat([hardline, path.call(print, "body", 0)])), - hardline, - "rescue StandardError", - indent(concat([hardline, path.call(print, "body", 1)])), - hardline, - "end" - ])), - retry: literal("retry"), - return: (path, opts, print) => { - const args = path.getValue().body[0].body[0]; - - if (!args) { - return "return"; - } - - if (args.body[0] && args.body[0].type === "paren") { - // Ignoring the parens node and just going straight to the content - return concat(["return ", path.call(print, "body", 0, "body", 0, "body", 0, "body", 0)]); - } - - return concat(["return ", join(", ", path.call(print, "body", 0))]); - }, - return0: literal("return"), - sclass: (path, opts, print) => group(concat([ - concat(["class << ", path.call(print, "body", 0)]), - indent(concat([hardline, path.call(print, "body", 1)])), - concat([hardline, "end"]) - ])), - stmts: (path, opts, print) => { - const parts = []; - let lineNo = null; - - path.getValue().body.forEach((stmt, index) => { - if (stmt.type === "void_stmt") { - return; - } - - const printed = path.call(print, "body", index); - - if (lineNo === null) { - parts.push(printed); - } else if (stmt.start - lineNo > 1) { - parts.push(hardline, hardline, printed); - } else if (stmt.start !== lineNo || path.getParentNode().type !== "string_embexpr") { - parts.push(hardline, printed); - } else { - parts.push("; ", printed); - } - - lineNo = stmt.end; - }); - - return concat(parts); - }, - super: (path, opts, print) => { - const args = path.getValue().body[0]; - - if (args.type === "arg_paren") { - // In case there are explicitly no arguments but they are using parens, - // we assume they are attempting to override the initializer and pass no - // arguments up. - if (args.body[0] === null) { - return "super()"; - } - - return concat(["super", path.call(print, "body", 0)]); - } - - return concat(["super ", join(", ", path.call(print, "body", 0))]); - }, - symbol: prefix(":"), - symbol_literal: concatBody, - top_const_field: prefix("::"), - top_const_ref: prefix("::"), - unary: (path, opts, print) => { - const operator = path.getValue().body[0]; - - return concat([ - operator === "not" ? "not " : operator[0], - path.call(print, "body", 1) - ]); - }, - undef: (path, opts, print) => group(concat([ - "undef ", - align( - "undef ".length, - join(concat([",", line]), path.map(print, "body", 0)) - ) - ])), - var_field: concatBody, - var_ref: first, - vcall: first, - when: (path, opts, print) => { - const [_predicates, _statements, addition] = path.getValue().body; - - const stmts = path.call(print, "body", 1); - const parts = [group(concat(["when ", join(", ", path.call(print, "body", 0))]))]; - - if (!stmts.parts.every(part => !part)) { - parts.push(indent(concat([hardline, stmts]))); - } - - if (addition) { - parts.push(concat([hardline, path.call(print, "body", 2)])); - } - - return group(concat(parts)); - }, - yield: (path, opts, print) => { - if (path.getValue().body[0].type === "paren") { - return concat(["yield", path.call(print, "body", 0)]); - } - - return concat(["yield ", join(", ", path.call(print, "body", 0))]); - }, - yield0: literal("yield"), - zsuper: literal("super") -}; - -module.exports = Object.assign( - {}, - require("./nodes/alias"), - require("./nodes/arrays"), - require("./nodes/blocks"), - require("./nodes/calls"), - require("./nodes/commands"), - require("./nodes/conditionals"), - require("./nodes/hooks"), - require("./nodes/loops"), - require("./nodes/methods"), - require("./nodes/params"), - require("./nodes/regexp"), - require("./nodes/strings"), - nodes -); diff --git a/src/nodes/alias.js b/src/nodes/alias.js deleted file mode 100644 index 13dba801..00000000 --- a/src/nodes/alias.js +++ /dev/null @@ -1,29 +0,0 @@ -const { concat, join } = require("prettier").doc.builders; - -const usingSymbols = path => { - const [left, right] = path.getValue().body.map(node => node.body[0].type); - return left === "symbol" && right === "symbol"; -}; - -const identFromSymbol = (path, print, index) => ( - path.call(print, "body", index, "body", 0, "body", 0) -); - -const aliasError = (_path, _opts, _print) => { - throw new Error("can't make alias for the number variables"); -}; - -const aliasVars = (path, opts, print) => { - if (usingSymbols(path)) { - return join(" ", [identFromSymbol(path, print, 0), identFromSymbol(path, print, 1)]); - } - return join(" ", path.map(print, "body")); -}; - -const alias = (path, opts, print) => concat(["alias ", aliasVars(path, opts, print)]); - -module.exports = { - alias, - alias_error: aliasError, - var_alias: alias -}; diff --git a/src/nodes/arrays.js b/src/nodes/arrays.js deleted file mode 100644 index 6cc6d7e8..00000000 --- a/src/nodes/arrays.js +++ /dev/null @@ -1,81 +0,0 @@ -const { concat, group, ifBreak, indent, join, line, softline } = require("prettier").doc.builders; - -const isStringArray = args => args.body.every(arg => ( - arg.type === "string_literal" - && arg.body[0].body.length === 1 - && arg.body[0].body[0].type === "@tstring_content" - && !arg.body[0].body[0].body.includes(" ") -)); - -const isSymbolArray = args => args.body.every(arg => ( - arg.type === "symbol_literal" -)); - -const makeArray = start => (path, opts, print) => ( - [start].concat(path.map(print, "body")) -); - -const getSpecialArrayParts = (path, print, args) => args.body.map((_arg, index) => ( - path.call(print, "body", 0, "body", index, "body", 0, "body", 0) -)); - -const printAref = (path, opts, print) => group(concat([ - path.call(print, "body", 0), - "[", - indent(concat([ - softline, - join(concat([",", line]), path.call(print, "body", 1)) - ])), - concat([softline, "]"]) -])); - -const printSpecialArray = parts => group(concat([ - parts[0], - "[", - indent(concat([softline, join(line, parts.slice(1))])), - concat([softline, "]"]) -])); - -module.exports = { - aref: (path, opts, print) => { - if (!path.getValue().body[1]) { - return concat([path.call(print, "body", 0), "[]"]); - } - - return printAref(path, opts, print); - }, - aref_field: printAref, - array: (path, { addTrailingCommas }, print) => { - const args = path.getValue().body[0]; - - if (args === null) { - return "[]"; - } - - if (isStringArray(args)) { - return printSpecialArray(["%w"].concat(getSpecialArrayParts(path, print, args))); - } - - if (isSymbolArray(args)) { - return printSpecialArray(["%i"].concat(getSpecialArrayParts(path, print, args))); - } - - if (["args", "args_add_star"].includes(args.type)) { - return group(concat([ - "[", - indent(concat([ - softline, - join(concat([",", line]), path.call(print, "body", 0)), - addTrailingCommas ? ifBreak(",", "") : "" - ])), - concat([softline, "]"]) - ])); - } - - return printSpecialArray(path.call(print, "body", 0)); - }, - qsymbols: makeArray("%i"), - qwords: makeArray("%w"), - symbols: makeArray("%I"), - words: makeArray("%W") -}; diff --git a/src/nodes/blocks.js b/src/nodes/blocks.js deleted file mode 100644 index a25e9621..00000000 --- a/src/nodes/blocks.js +++ /dev/null @@ -1,126 +0,0 @@ -const { breakParent, concat, group, ifBreak, indent, softline } = require("prettier").doc.builders; - -const isCall = node => ["::", "."].includes(node) || node.type === "@period"; - -// If you have a simple block that only calls a method on the single required -// parameter that is passed to it, then you can replace that block with the -// simpler `Symbol#to_proc`. Meaning, it would go from: -// -// [1, 2, 3].map { |i| i.to_s } -// -// to: -// -// [1, 2, 3].map(&:to_s) -// -// This additionally works with `do` blocks as well. -const toProcTransform = path => { - const [variables, blockContents] = path.getValue().body; - - // Ensure that there are variables being passed to this block. - const params = variables && variables.body[0]; - if (!params || params.type !== "params") { - return null; - } - - // Ensure there is one and only one parameter, and that it is required. - const reqParams = params.body[0]; - const otherParams = params.body.slice(1); - if (!Array.isArray(reqParams) || reqParams.length !== 1 || otherParams.some(Boolean)) { - return null; - } - - let statements; - if (blockContents.type === "bodystmt") { - // We’re in a `do` block - const blockStatements = blockContents.body[0]; - const rescueElseEnsure = blockStatements.body.slice(1); - - // You can’t use the to_proc shortcut if you’re rescuing - if (rescueElseEnsure.some(Boolean)) { - return null; - } - - statements = blockStatements; - } else { - // We’re in a brace block - statements = blockContents; - } - - // Ensure the block contains only one statement - if (statements.body.length !== 1) { - return null; - } - - // Ensure that statement is a call - const [statement] = statements.body; - if (statement.type !== "call") { - return null; - } - - // Ensure the call is a method of the block argument - const [varRef, call, method, args] = statement.body; - - if ( - varRef.type === "var_ref" - && varRef.body[0].body === reqParams[0].body - && isCall(call) - && method.type === "@ident" - && !args - ) { - if (["command", "command_call"].includes(path.getParentNode().body[0].type)) { - return `, &:${method.body}`; - } - - return `(&:${method.body})`; - } - - return null; -}; - -const printBlock = (path, opts, print) => { - const toProcResponse = toProcTransform(path); - if (toProcResponse) { - return toProcResponse; - } - - const [variables, statements] = path.getValue().body; - const stmts = statements.type === "stmts" ? statements.body : statements.body[0].body; - - let doBlockBody = ""; - if (stmts.length !== 1 || stmts[0].type !== "void_stmt") { - doBlockBody = indent(concat([softline, path.call(print, "body", 1)])); - } - - const doBlock = concat([ - " do", - variables ? concat([" ", path.call(print, "body", 0)]) : "", - doBlockBody, - concat([softline, "end"]) - ]); - - // We can hit this next pattern if within the block the only statement is a - // comment. - if (stmts.length > 1 && stmts.filter(stmt => stmt.type !== "@comment").length === 1) { - return concat([breakParent, doBlock]); - } - - // If the parent node is a command node, then there are no parentheses around - // the arguments to that command, so we need to break the block - if (["command", "command_call"].includes(path.getParentNode().body[0].type)) { - return concat([breakParent, doBlock]); - } - - const braceBlock = concat([ - " { ", - variables ? path.call(print, "body", 0) : "", - path.call(print, "body", 1), - " }" - ]); - - return group(ifBreak(doBlock, braceBlock)); -}; - -module.exports = { - brace_block: printBlock, - do_block: printBlock -}; diff --git a/src/nodes/calls.js b/src/nodes/calls.js deleted file mode 100644 index dbf09cd7..00000000 --- a/src/nodes/calls.js +++ /dev/null @@ -1,31 +0,0 @@ -const { concat, group, indent, softline } = require("prettier").doc.builders; -const { makeCall } = require("../utils"); - -const noIndent = [ - "array", - "hash", - "method_add_block", - "xstring_literal" -]; - -module.exports = { - call: (path, opts, print) => { - const receiver = path.call(print, "body", 0); - const operator = makeCall(path, opts, print); - let name = path.getValue().body[2]; - - // You can call lambdas with a special syntax that looks like func.(*args). - // In this case, "call" is returned for the 3rd child node. - if (name !== "call") { - name = path.call(print, "body", 2); - } - - // For certain left sides of the call nodes, we want to attach directly to - // the } or end. - if (noIndent.includes(path.getValue().body[0].type)) { - return concat([receiver, operator, name]); - } - - return group(concat([receiver, indent(concat([softline, operator, name]))])); - } -}; diff --git a/src/nodes/commands.js b/src/nodes/commands.js deleted file mode 100644 index 3a629244..00000000 --- a/src/nodes/commands.js +++ /dev/null @@ -1,55 +0,0 @@ -const { align, concat, group, ifBreak, join, line } = require("prettier").doc.builders; -const { docLength, makeArgs, makeCall } = require("../utils"); - -module.exports = { - command: (path, opts, print) => { - const command = path.call(print, "body", 0); - const { args, heredocs } = makeArgs(path, opts, print, 1); - - if (heredocs.length > 1) { - return concat([command, " ", join(", ", args)].concat(heredocs)); - } - - const joinedArgs = join(concat([",", line]), args); - const commandDoc = group(ifBreak( - concat([command, " ", align(command.length + 1, joinedArgs)]), - concat([command, " ", joinedArgs]) - )); - - if (heredocs.length === 1) { - return group(concat([commandDoc].concat(heredocs))); - } - - return commandDoc; - }, - command_call: (path, opts, print) => { - const parts = [ - path.call(print, "body", 0), - makeCall(path, opts, print), - path.call(print, "body", 2) - ]; - - if (!path.getValue().body[3]) { - return concat(parts); - } - - parts.push(" "); - const { args, heredocs } = makeArgs(path, opts, print, 3); - - if (heredocs.length > 1) { - return concat(parts.concat([join(", ", args)]).concat(heredocs)); - } - - const joinedArgs = join(concat([",", line]), args); - const commandDoc = group(ifBreak( - concat(parts.concat([align(docLength(concat(parts)), joinedArgs)])), - concat(parts.concat([joinedArgs])) - )); - - if (heredocs.length === 1) { - return group(concat([commandDoc].concat(heredocs))); - } - - return commandDoc; - } -}; diff --git a/src/nodes/conditionals.js b/src/nodes/conditionals.js deleted file mode 100644 index 2d1b860b..00000000 --- a/src/nodes/conditionals.js +++ /dev/null @@ -1,127 +0,0 @@ -const { align, breakParent, concat, hardline, group, ifBreak, indent, softline } = require("prettier").doc.builders; - -const noTernary = [ - "@comment", - "alias", - "assign", - "break", - "command", - "command_call", - "if_mod", - "ifop", - "lambda", - "massign", - "next", - "opassign", - "rescue_mod", - "return", - "return0", - "super", - "undef", - "unless_mod", - "until_mod", - "var_alias", - "void_stmt", - "while_mod", - "yield", - "yield0", - "zsuper" -]; - -const printWithAddition = (keyword, path, print, { breaking = false } = {}) => concat([ - `${keyword} `, - align(keyword.length - 1, path.call(print, "body", 0)), - indent(concat([softline, path.call(print, "body", 1)])), - concat([softline, path.call(print, "body", 2)]), - concat([softline, "end"]), - breaking ? breakParent : "" -]); - -const printTernaryConditions = (keyword, truthyValue, falsyValue) => { - const parts = [truthyValue, " : ", falsyValue]; - return keyword === "if" ? parts : parts.reverse(); -}; - -const canTernary = stmts => ( - stmts.body.length === 1 && !noTernary.includes(stmts.body[0].type) -); - -const printConditional = keyword => (path, { inlineConditionals }, print) => { - const [_predicate, stmts, addition] = path.getValue().body; - - // If the addition is not an elsif or an else, then it's the second half of a - // ternary expression - if (addition && addition.type !== "elsif" && addition.type !== "else") { - const parts = [path.call(print, "body", 0), " ? "]; - const truthyValue = path.call(print, "body", 1); - const falsyValue = path.call(print, "body", 2); - - return group(ifBreak( - concat([ - `${keyword} `, - path.call(print, "body", 0), - indent(concat([softline, path.call(print, "body", 1)])), - concat([softline, "else"]), - indent(concat([softline, path.call(print, "body", 2)])), - concat([softline, "end"]) - ]), - concat(parts.concat(printTernaryConditions(keyword, truthyValue, falsyValue))) - )); - } - - // If there is an else and only an else, attempt to shorten to a ternary - if (addition && addition.type === "else" && canTernary(stmts) && canTernary(addition.body[0])) { - const ternary = printTernaryConditions( - keyword, - path.call(print, "body", 1), - path.call(print, "body", 2, "body", 0) - ); - - return group(ifBreak( - printWithAddition(keyword, path, print), - concat([path.call(print, "body", 0), " ? "].concat(ternary)) - )); - } - - // If there's an additional clause, we know we can't go for the inline option - if (addition) { - return group(printWithAddition(keyword, path, print, { breaking: true })); - } - - // If it's short enough, favor the inline conditional - return group(ifBreak( - concat([ - `${keyword} `, - align(keyword.length - 1, path.call(print, "body", 0)), - indent(concat([softline, path.call(print, "body", 1)])), - concat([softline, "end"]) - ]), - concat([ - inlineConditionals ? "" : breakParent, - path.call(print, "body", 1), - ` ${keyword} `, - path.call(print, "body", 0) - ]) - )); -}; - -module.exports = { - elsif: (path, opts, print) => { - const [_predicate, _statements, addition] = path.getValue().body; - const parts = [ - group(concat(["elsif ", align("elsif".length - 1, path.call(print, "body", 0))])), - indent(concat([hardline, path.call(print, "body", 1)])) - ]; - - if (addition) { - parts.push(group(concat([hardline, path.call(print, "body", 2)]))); - } - - return group(concat(parts)); - }, - if: printConditional("if"), - ifop: printConditional("if"), - if_mod: printConditional("if"), - unless: printConditional("unless"), - unless_mod: printConditional("unless") -}; diff --git a/src/nodes/hooks.js b/src/nodes/hooks.js deleted file mode 100644 index ea158edc..00000000 --- a/src/nodes/hooks.js +++ /dev/null @@ -1,12 +0,0 @@ -const { concat, group, indent, line } = require("prettier").doc.builders; - -const printHook = name => (path, opts, print) => group(concat([ - `${name} {`, - indent(concat([line, path.call(print, "body", 0)])), - concat([line, "}"]) -])); - -module.exports = { - BEGIN: printHook("BEGIN"), - END: printHook("END") -}; diff --git a/src/nodes/loops.js b/src/nodes/loops.js deleted file mode 100644 index 7f1ba0f8..00000000 --- a/src/nodes/loops.js +++ /dev/null @@ -1,32 +0,0 @@ -const { breakParent, concat, group, hardline, ifBreak, indent, softline } = require("prettier").doc.builders; - -const printLoop = keyword => (path, { inlineLoops }, print) => group(ifBreak( - concat([ - concat([`${keyword} `, path.call(print, "body", 0)]), - indent(concat([softline, path.call(print, "body", 1)])), - concat([softline, "end"]) - ]), - concat([ - inlineLoops ? "" : breakParent, - path.call(print, "body", 1), - ` ${keyword} `, - path.call(print, "body", 0) - ]) -)); - -const printFor = (path, opts, print) => group(concat([ - path.call(print, "body", 1), - ".each do |", - path.call(print, "body", 0), - "|", - indent(concat([hardline, path.call(print, "body", 2)])), - concat([hardline, "end"]) -])); - -module.exports = { - while: printLoop("while"), - while_mod: printLoop("while"), - until: printLoop("until"), - until_mod: printLoop("until"), - for: printFor -}; diff --git a/src/nodes/methods.js b/src/nodes/methods.js deleted file mode 100644 index f4f8f5eb..00000000 --- a/src/nodes/methods.js +++ /dev/null @@ -1,39 +0,0 @@ -const { concat, group, hardline, indent } = require("prettier").doc.builders; - -const printMethod = offset => (path, opts, print) => { - const [_name, params, body] = path.getValue().body.slice(offset); - const declaration = ["def "]; - - // In this case, we're printing a method that's defined as a singleton, so we - // need to include the target and the operator - if (offset > 0) { - declaration.push(path.call(print, "body", 0), path.call(print, "body", 1)); - } - - // In case there are no parens but there are arguments - const parens = params.type === "params" && params.body.some(paramType => paramType); - - declaration.push( - path.call(print, "body", offset), - parens ? "(" : "", - path.call(print, "body", offset + 1), - parens ? ")" : "" - ); - - // If the body is empty, we can replace with a ; - const stmts = body.body[0].body; - if (stmts.length === 1 && stmts[0].type === "void_stmt") { - return group(concat(declaration.concat(["; end"]))); - } - - return group(concat([ - group(concat(declaration)), - indent(concat([hardline, path.call(print, "body", offset + 2)])), - group(concat([hardline, "end"])) - ])); -}; - -module.exports = { - def: printMethod(0), - defs: printMethod(2) -}; diff --git a/src/nodes/params.js b/src/nodes/params.js deleted file mode 100644 index f027fb7e..00000000 --- a/src/nodes/params.js +++ /dev/null @@ -1,60 +0,0 @@ -const { concat, group, join, line } = require("prettier").doc.builders; - -const printGenericRestParam = symbol => (path, opts, print) => ( - path.getValue().body[0] ? concat([symbol, path.call(print, "body", 0)]) : symbol -); - -const printParams = (path, opts, print) => { - const [reqs, optls, rest, post, kwargs, kwargRest, block] = path.getValue().body; - let parts = []; - - if (reqs) { - parts = parts.concat(path.map(print, "body", 0)); - } - - if (optls) { - parts = parts.concat(optls.map((_, index) => concat([ - path.call(print, "body", 1, index, 0), - " = ", - path.call(print, "body", 1, index, 1) - ]))); - } - - if (rest) { - parts.push(path.call(print, "body", 2)); - } - - if (post) { - parts = parts.concat(path.map(print, "body", 3)); - } - - if (kwargs) { - parts = parts.concat(kwargs.map(([, value], index) => { - if (!value) { - return path.call(print, "body", 4, index, 0); - } - return group(join(" ", path.map(print, "body", 4, index))); - })); - } - - if (kwargRest) { - parts.push(path.call(print, "body", 5)); - } - - if (block) { - parts.push(path.call(print, "body", 6)); - } - - return group(join(concat([",", line]), parts)); -}; - -const paramError = () => { - throw new Error("formal argument cannot be a global variable"); -}; - -module.exports = { - kwrest_param: printGenericRestParam("**"), - rest_param: printGenericRestParam("*"), - params: printParams, - param_error: paramError -}; diff --git a/src/nodes/regexp.js b/src/nodes/regexp.js deleted file mode 100644 index 2cc38485..00000000 --- a/src/nodes/regexp.js +++ /dev/null @@ -1,13 +0,0 @@ -const { concat } = require("prettier").doc.builders; -const { makeList } = require("../utils"); - -module.exports = { - regexp: makeList, - regexp_literal: (path, opts, print) => { - const [contents, ending] = path.map(print, "body"); - const useBraces = contents.some(content => typeof content === "string" && content.includes("/")); - const parts = [useBraces ? "%r{" : "/"].concat(contents).concat([useBraces ? "}" : "/", ending.slice(1)]); - - return concat(parts); - } -}; diff --git a/src/nodes/strings.js b/src/nodes/strings.js deleted file mode 100644 index 4ca85d6f..00000000 --- a/src/nodes/strings.js +++ /dev/null @@ -1,131 +0,0 @@ -const { concat, group, hardline, indent, join, literalline, softline } = require("prettier").doc.builders; -const { concatBody, empty, makeList, surround } = require("../utils"); -const escapePattern = require("../escapePattern"); - -// If there is some part of this string that matches an escape sequence or that -// contains the interpolation pattern ("#{"), then we are locked into whichever -// quote the user chose. (If they chose single quotes, then double quoting -// would activate the escape sequence, and if they chose double quotes, then -// single quotes would deactivate it.) -const isQuoteLocked = string => string.body.some(part => ( - part.type === "@tstring_content" && ( - escapePattern.test(part.body) || part.body.includes("#{") - ) -)); - -// A string is considered to be able to use single quotes if it contains only -// plain string content and that content does not contain a single quote. -const isSingleQuotable = string => string.body.every(part => ( - part.type === "@tstring_content" && !part.body.includes("'") -)); - -const getStringQuote = (string, preferSingleQuotes) => { - if (isQuoteLocked(string)) { - return string.quote; - } - - return preferSingleQuotes && isSingleQuotable(string) ? "'" : "\""; -}; - -const quotePattern = new RegExp("\\\\([\\s\\S])|(['\"])", "g"); - -const makeString = (content, enclosingQuote) => { - const otherQuote = enclosingQuote === "\"" ? "'" : enclosingQuote; - - // Escape and unescape single and double quotes as needed to be able to - // enclose `content` with `enclosingQuote`. - return content.replace(quotePattern, (match, escaped, quote) => { - if (escaped === otherQuote) { - return escaped; - } - - if (quote === enclosingQuote) { - return `\\${quote}`; - } - - if (quote) { - return quote; - } - - return `\\${escaped}`; - }); -}; - -module.exports = { - "@CHAR": (path, { preferSingleQuotes }, _print) => { - const { body } = path.getValue(); - - if (body.length !== 2) { - return body; - } - - const quote = preferSingleQuotes ? "'" : "\""; - return body.length === 2 ? concat([quote, body.slice(1), quote]) : body; - }, - heredoc: (path, opts, print) => { - const { beging, ending } = path.getValue(); - - return concat([ - beging, - concat([literalline].concat(path.map(print, "body"))), - ending - ]); - }, - string: makeList, - string_concat: (path, opts, print) => group(concat([ - path.call(print, "body", 0), - " \\", - indent(concat([hardline, path.call(print, "body", 1)])) - ])), - string_dvar: surround("#{", "}"), - string_embexpr: (path, opts, print) => { - const stmts = path.getValue().body[0].body; - const isHeredoc = stmts.length === 1 && ( - stmts[0].type === "heredoc" || (stmts[0].body[0] && stmts[0].body[0].type === "heredoc") - ); - - return concat([ - "#{", - path.call(print, "body", 0), - concat([isHeredoc ? hardline : "", "}"]) - ]); - }, - string_literal: (path, { preferSingleQuotes }, print) => { - const string = path.getValue().body[0]; - - // If this string is actually a heredoc, bail out and return to the print - // function for heredocs - if (string.type === "heredoc") { - return path.call(print, "body", 0); - } - - // If the string is empty, it will not have any parts, so just print out the - // quotes corresponding to the config - if (string.body.length === 0) { - return preferSingleQuotes ? "''" : "\"\""; - } - - const quote = getStringQuote(string, preferSingleQuotes); - const parts = []; - - string.body.forEach((part, index) => { - if (part.type === "@tstring_content") { - // In this case, the part of the string is just regular string content - parts.push(makeString(part.body, quote)); - } else { - // In this case, the part of the string is an embedded expression - parts.push(path.call(print, "body", 0, "body", index)); - } - }); - - return concat([quote].concat(parts).concat([quote])); - }, - word_add: concatBody, - word_new: empty, - xstring: makeList, - xstring_literal: (path, opts, print) => group(concat([ - "`", - indent(concat([softline, join(softline, path.call(print, "body", 0))])), - concat([softline, "`"]) - ])) -}; diff --git a/src/parse.js b/src/parse.js deleted file mode 100644 index 5a90def8..00000000 --- a/src/parse.js +++ /dev/null @@ -1,14 +0,0 @@ -const { spawnSync } = require("child_process"); -const path = require("path"); - -module.exports = (text, _parsers, _opts) => { - const child = spawnSync("ruby", [path.join(__dirname, "./ripper.rb")], { input: text }); - - const error = child.stderr.toString(); - if (error) { - throw new Error(error); - } - - const response = child.stdout.toString(); - return JSON.parse(response); -}; diff --git a/src/plugin.js b/src/plugin.js new file mode 100644 index 00000000..71d2030b --- /dev/null +++ b/src/plugin.js @@ -0,0 +1,381 @@ +import { spawn } from "child_process"; +import fs from "fs"; +import net from "net"; +import os from "os"; +import path from "path"; +import process from "process"; +import url from "url"; +import { resolveConfigFile } from "prettier"; + +// In order to properly parse ruby code, we need to tell the ruby process to +// parse using UTF-8. Unfortunately, the way that you accomplish this looks +// differently depending on your platform. +function getLang() { + const { env, platform } = process; + const envValue = env.LC_ALL || env.LC_CTYPE || env.LANG; + + // If an env var is set for the locale that already includes UTF-8 in the + // name, then assume we can go with that. + if (envValue && envValue.includes("UTF-8")) { + return envValue; + } + + // Otherwise, we're going to guess which encoding to use based on the system. + // This is probably not the best approach in the world, as you could be on + // linux and not have C.UTF-8, but in that case you're probably passing an env + // var for it. This object below represents all of the possible values of + // process.platform per: + // https://nodejs.org/api/process.html#process_process_platform + return { + aix: "C.UTF-8", + android: "C.UTF-8", + cygwin: "C.UTF-8", + darwin: "en_US.UTF-8", + freebsd: "C.UTF-8", + haiku: "C.UTF-8", + linux: "C.UTF-8", + netbsd: "C.UTF-8", + openbsd: "C.UTF-8", + sunos: "C.UTF-8", + win32: ".UTF-8" + }[platform]; +} + +// Return the list of plugins that should be passed to the server process. +function getPlugins(opts) { + const plugins = new Set(); + + const rubyPlugins = opts.rubyPlugins.trim(); + if (rubyPlugins.length > 0) { + rubyPlugins.split(",").forEach((plugin) => plugins.add(plugin.trim())); + } + + if (opts.rubySingleQuote) { + plugins.add("plugin/single_quotes"); + } + + if (opts.trailingComma !== "none") { + plugins.add("plugin/trailing_comma"); + } + + return Array.from(plugins); +} + +// Create a file that will act as a communication mechanism, spawn a parser +// server with that filepath as an argument, then wait for the file to be +// created that will contain the connection information. +export async function spawnServer(opts, killOnExit = true) { + const tmpdir = os.tmpdir(); + const filepath = path.join(tmpdir, `prettier-ruby-parser-${process.pid}.txt`); + + const options = { + env: Object.assign({}, process.env, { LANG: getLang() }), + stdio: ["ignore", "ignore", "inherit"], + detached: true + }; + + if (opts.filepath) { + const prettierConfig = await resolveConfigFile(opts.filepath); + options.cwd = path.dirname(prettierConfig); + } + + const server = spawn( + opts.rubyExecutablePath || "ruby", + [ + url.fileURLToPath(new URL("./server.rb", import.meta.url)), + `--plugins=${getPlugins(opts).join(",")}`, + filepath + ], + options + ); + + server.unref(); + + if (killOnExit) { + process.on("exit", () => { + if (fs.existsSync(filepath)) { + fs.unlinkSync(filepath); + } + + try { + if (server.pid) { + // Kill the server process if it's still running. If we're on windows + // we're going to use the process ID number. If we're not, we're going + // to use the negative process ID to indicate the group. + const pid = process.platform === "win32" ? server.pid : -server.pid; + process.kill(pid); + } + } catch (error) { + // If there's an error killing the process, we're going to ignore it. + } + }); + } + + return new Promise((resolve, reject) => { + const interval = setInterval(() => { + if (fs.existsSync(filepath)) { + const connectionJSON = fs.readFileSync(filepath).toString("utf-8"); + resolve({ + serverPID: server.pid, + connectionFilepath: filepath, + connectionOptions: JSON.parse(connectionJSON) + }); + + clearTimeout(timeout); + clearInterval(interval); + } else if (server.exitCode) { + reject(new Error("Failed to start parse server.")); + clearTimeout(timeout); + clearInterval(interval); + } + }, 100); + + const timeout = setTimeout( + () => { + const message = + "Failed to get connection options from parse server in time. If this happens repeatedly, try increasing the PRETTIER_RUBY_TIMEOUT_MS environment variable beyond 10000."; + + clearInterval(interval); + reject(new Error(message)); + }, + parseInt(process.env.PRETTIER_RUBY_TIMEOUT_MS || "10000", 10) + ); + }); +} + +let connectionOptions; +if (process.env.PRETTIER_RUBY_HOST) { + connectionOptions = JSON.parse(process.env.PRETTIER_RUBY_HOST); +} + +// Formats and sends an asynchronous request to the parser server. +async function parse(parser, source, opts) { + if (!connectionOptions) { + const spawnedServer = await spawnServer(opts); + connectionOptions = spawnedServer.connectionOptions; + } + + return new Promise((resolve, reject) => { + const socket = new net.Socket(); + let chunks = ""; + + socket.on("error", (error) => { + reject(error); + }); + + socket.on("data", (data) => { + chunks += data.toString("utf-8"); + }); + + socket.on("end", () => { + const response = JSON.parse(chunks); + + if (response.error) { + const error = new Error(response.error); + if (response.loc) { + error.loc = response.loc; + } + + reject(error); + } + + resolve(response); + }); + + socket.connect(connectionOptions, () => { + socket.end( + JSON.stringify({ + parser, + source, + maxwidth: opts.printWidth, + tabwidth: opts.tabWidth + }) + ); + }); + }); +} + +// Metadata mostly pulled from linguist and rubocop: +// https://github.com/github/linguist/blob/master/lib/linguist/languages.yml +// https://github.com/rubocop/rubocop/blob/master/spec/rubocop/target_finder_spec.rb +const plugin = { + languages: [ + { + name: "Ruby", + parsers: ["ruby"], + extensions: [ + ".arb", + ".axlsx", + ".builder", + ".eye", + ".fcgi", + ".gemfile", + ".gemspec", + ".god", + ".jb", + ".jbuilder", + ".mspec", + ".opal", + ".pluginspec", + ".podspec", + ".rabl", + ".rake", + ".rb", + ".rbi", + ".rbuild", + ".rbw", + ".rbx", + ".ru", + ".ruby", + ".thor", + ".watchr" + ], + filenames: [ + ".irbrc", + ".pryrc", + ".simplecov", + "Appraisals", + "Berksfile", + "Brewfile", + "Buildfile", + "Capfile", + "Cheffile", + "Dangerfile", + "Deliverfile", + "Fastfile", + "Gemfile", + "Guardfile", + "Jarfile", + "Mavenfile", + "Podfile", + "Puppetfile", + "Rakefile", + "Snapfile", + "Thorfile", + "Vagabondfile", + "Vagrantfile", + "buildfile" + ], + interpreters: ["jruby", "macruby", "rake", "rbx", "ruby"], + linguistLanguageId: 326, + vscodeLanguageIds: ["ruby"] + }, + { + name: "RBS", + parsers: ["rbs"], + extensions: [".rbs"] + }, + { + name: "HAML", + parsers: ["haml"], + extensions: [".haml"], + vscodeLanguageIds: ["haml"] + } + ], + parsers: { + ruby: { + parse(text, opts) { + return parse("ruby", text, opts); + }, + astFormat: "ruby", + hasPragma(text) { + return /^\s*#[^\S\n]*@(?:prettier|format)\s*?(?:\n|$)/m.test(text); + }, + locStart() { + return 0; + }, + locEnd() { + return 0; + } + }, + rbs: { + parse(text, opts) { + return parse("rbs", text, opts); + }, + astFormat: "rbs", + hasPragma(text) { + return /^\s*#[^\S\n]*@(prettier|format)\s*(\n|$)/.test(text); + }, + locStart() { + return 0; + }, + locEnd() { + return 0; + } + }, + haml: { + parse(text, opts) { + return parse("haml", text, opts); + }, + astFormat: "haml", + hasPragma(text) { + return /^\s*-#\s*@(prettier|format)/.test(text); + }, + locStart() { + return 0; + }, + locEnd() { + return 0; + } + } + }, + printers: { + ruby: { + print(path) { + return path.getValue(); + }, + insertPragma(text) { + return `# @format${text.startsWith("#") ? "\n" : "\n\n"}${text}`; + } + }, + rbs: { + print(path) { + return path.getValue(); + }, + insertPragma(text) { + return `# @format${text.startsWith("#") ? "\n" : "\n\n"}${text}`; + } + }, + haml: { + print(path) { + return path.getValue(); + }, + insertPragma(text) { + return `-# @format${text.startsWith("-#") ? "\n" : "\n\n"}${text}`; + } + } + }, + options: { + rubyPlugins: { + type: "string", + category: "Ruby", + default: "", + description: "The comma-separated list of plugins to require.", + since: "3.1.0" + }, + rubySingleQuote: { + type: "boolean", + category: "Ruby", + default: false, + description: + "When double quotes are not necessary for interpolation, prefers the use of single quotes for string literals.", + since: "1.0.0" + }, + rubyExecutablePath: { + type: "string", + category: "Ruby", + default: "ruby", + description: + "The path to the Ruby executable to use to run the formatter.", + since: "3.3.0" + } + }, + defaultOptions: { + printWidth: 80, + tabWidth: 2, + trailingComma: "none", + singleQuote: false + } +}; + +export default plugin; diff --git a/src/print.js b/src/print.js deleted file mode 100644 index 74787049..00000000 --- a/src/print.js +++ /dev/null @@ -1,21 +0,0 @@ -const { printComments } = require("./utils"); -const nodes = require("./nodes"); - -module.exports = (path, opts, print) => { - const { type, body, comments, start } = path.getValue(); - - if (type in nodes) { - const printed = nodes[type](path, opts, print); - - if (comments) { - return printComments(printed, start, comments); - } - return printed; - } - - if (type[0] === "@") { - return body; - } - - throw new Error(`Unsupported node encountered: ${type}\n${JSON.stringify(body, null, 2)}`); -}; diff --git a/src/ripper.rb b/src/ripper.rb deleted file mode 100755 index a62cdb27..00000000 --- a/src/ripper.rb +++ /dev/null @@ -1,419 +0,0 @@ -#!/usr/bin/env ruby - -REQUIRED_VERSION = Gem::Version.new('2.5') -if Gem::Version.new(RUBY_VERSION) < REQUIRED_VERSION - raise "Ruby version #{RUBY_VERSION} not supported. " \ - "Please upgrade to #{REQUIRED_VERSION} or above." -end - -require 'json' unless defined?(JSON) -require 'ripper' - -module Layer - # Some nodes are lists that come back from the parser. They always start with - # a *_new node (or in the case of string, *_content) and each additional node - # in the list is a *_add node. This layer takes those nodes and turns them - # into one node with an array body. - module Lists - events = %i[ - args - mlhs - mrhs - qsymbols - qwords - regexp - stmts - string - symbols - words - xstring - ] - - private - - events.each do |event| - suffix = event == :string ? 'content' : 'new' - - define_method(:"on_#{event}_#{suffix}") do - { type: event, body: [], start: lineno, end: lineno } - end - - define_method(:"on_#{event}_add") do |parts, part| - parts.tap do |node| - node[:body] << part - node[:end] = lineno - end - end - end - end - - # For most nodes, it's enough to look at the child nodes to determine the - # start of the parent node. However, for some nodes it's necessary to keep - # track of the keywords as they come in from the lexer and to modify the start - # node once we have it. - module StartLine - events = %i[begin else elsif ensure rescue until while] - - def initialize(*args) - super(*args) - @keywords = [] - end - - def self.prepended(base) - base.attr_reader :keywords - end - - private - - def find_start(body) - keywords[keywords.rindex { |keyword| keyword[:body] == body }][:start] - end - - events.each do |event| - keyword = event.to_s - - define_method(:"on_#{event}") do |*body| - super(*body).tap { |sexp| sexp.merge!(start: find_start(keyword)) } - end - end - - def on_kw(body) - super(body).tap { |sexp| keywords << sexp } - end - - def on_program(*body) - super(*body).tap { |sexp| sexp.merge!(start: 1) } - end - end - - # Nodes that are always on their own line occur when the lexer is in the - # EXPR_BEG node. Those comments are tracked within the @block_comments - # instance variable. Then for each node that could contain them, we attach - # them after the node has been built. - module BlockComments - events = { - begin: [0, :body, 0], - bodystmt: [0], - class: [2, :body, 0], - def: [2, :body, 0], - defs: [4, :body, 0], - else: [0], - elsif: [1], - ensure: [0], - if: [1], - program: [0], - rescue: [2], - sclass: [1, :body, 0], - unless: [1], - until: [1], - when: [1], - while: [1] - } - - def initialize(*args) - super(*args) - @block_comments = [] - @current_embdoc = nil - end - - def self.prepended(base) - base.attr_reader :block_comments, :current_embdoc - end - - private - - def attach_comments(sexp, stmts) - range = sexp[:start]..sexp[:end] - comments = - block_comments.group_by { |comment| range.include?(comment[:start]) } - - if comments[true] - stmts[:body] = - (stmts[:body] + comments[true]).sort_by { |node| node[:start] } - - @block_comments = comments.fetch(false) { [] } - end - end - - events.each do |event, path| - define_method(:"on_#{event}") do |*body| - super(*body).tap { |sexp| attach_comments(sexp, body.dig(*path)) } - end - end - - def on_comment(body) - super(body).tap do |sexp| - block_comments << sexp if RipperJS.lex_state_name(state) == 'EXPR_BEG' - end - end - - def on_embdoc_beg(comment) - @current_embdoc = { - type: :embdoc, body: comment, start: lineno, end: lineno - } - end - - def on_embdoc(comment) - @current_embdoc[:body] << comment - end - - def on_embdoc_end(comment) - @current_embdoc[:body] << comment.chomp - @block_comments << @current_embdoc - @current_embdoc = nil - end - - def on_method_add_block(*body) - super(*body).tap do |sexp| - stmts = body[1][:body][1] - stmts = stmts[:type] == :stmts ? stmts : body[1][:body][1][:body][0] - - attach_comments(sexp, stmts) - end - end - end - - # Tracking heredocs in somewhat interesting. Straight-line heredocs are - # reported as strings, whereas squiggly-line heredocs are reported as - # heredocs. - module Heredocs - def initialize(*args) - super(*args) - @heredoc_stack = [] - end - - def self.prepended(base) - base.attr_reader :heredoc_stack - end - - private - - def on_embexpr_beg(body) - super(body).tap { |sexp| heredoc_stack << sexp } - end - - def on_embexpr_end(body) - super(body).tap { heredoc_stack.pop } - end - - def on_heredoc_beg(beging) - heredoc = { type: :heredoc, beging: beging, start: lineno, end: lineno } - heredoc_stack << heredoc - end - - def on_heredoc_end(ending) - heredoc_stack[-1].merge!(ending: ending.chomp, end: lineno) - end - - def on_heredoc_dedent(string, _width) - heredoc = heredoc_stack.pop - string.merge!(heredoc.slice(:type, :beging, :ending, :start, :end)) - end - - def on_string_literal(string) - heredoc = heredoc_stack[-1] - - if heredoc && string[:type] != :heredoc && heredoc[:type] == :heredoc - heredoc_stack.pop - string.merge!(heredoc.slice(:type, :beging, :ending, :start, :end)) - else - super - end - end - end - - # These are the event types that contain _actual_ string content. If there is - # an encoding magic comment at the top of the file, ripper will actually - # change into that encoding for the storage of the string. This will break - # everything, so we need to force the encoding back into UTF-8 so that - # the JSON library won't break. - module Encoding - events = %w[comment ident tstring_content] - - events.each do |event| - define_method(:"on_#{event}") do |body| - super(body.force_encoding('UTF-8')) - end - end - end - - # This layer keeps track of inline comments as they come in. Ripper itself - # doesn't attach comments to the AST, so we need to do it manually. In this - # case, inline comments are defined as any comments wherein the lexer state is - # not equal to EXPR_BEG (tracked in the BlockComments layer). - module InlineComments - # Certain events needs to steal the comments from their children in order - # for them to display properly. - events = { - args_add_block: [:body, 0], - assoc_new: [:body, 1], - break: [:body, 0], - command: [:body, 1], - string_literal: [:body, 0] - } - - def initialize(*args) - super(*args) - @inline_comments = [] - @last_sexp = nil - end - - def self.prepended(base) - base.attr_reader :inline_comments, :last_sexp - end - - private - - events.each do |event, path| - define_method(:"on_#{event}") do |*body| - @last_sexp = - super(*body).tap do |sexp| - comments = sexp.dig(*path).delete(:comments) - sexp.merge!(comments: comments) if comments - end - end - end - - SPECIAL_LITERALS = %i[qsymbols qwords symbols words].freeze - - # Special array literals are handled in different ways and so their comments - # need to be passed up to their parent array node. - def on_array(*body) - @last_sexp = - super(*body).tap do |sexp| - next unless SPECIAL_LITERALS.include?(body.dig(0, :type)) - - comments = sexp.dig(:body, 0).delete(:comments) - sexp.merge!(comments: comments) if comments - end - end - - # Most scanner events don't stand on their own a s-expressions, but the CHAR - # scanner event is effectively just a string, so we need to track it as a - # s-expression. - def on_CHAR(body) - @last_sexp = super(body) - end - - # We need to know exactly where the comment is, switching off the current - # lexer state. In Ruby 2.7.0-dev, that's defined as: - # - # enum lex_state_bits { - # EXPR_BEG_bit, /* ignore newline, +/- is a sign. */ - # EXPR_END_bit, /* newline significant, +/- is an operator. */ - # EXPR_ENDARG_bit, /* ditto, and unbound braces. */ - # EXPR_ENDFN_bit, /* ditto, and unbound braces. */ - # EXPR_ARG_bit, /* newline significant, +/- is an operator. */ - # EXPR_CMDARG_bit, /* newline significant, +/- is an operator. */ - # EXPR_MID_bit, /* newline significant, +/- is an operator. */ - # EXPR_FNAME_bit, /* ignore newline, no reserved words. */ - # EXPR_DOT_bit, /* right after `.' or `::', no reserved words. */ - # EXPR_CLASS_bit, /* immediate after `class', no here document. */ - # EXPR_LABEL_bit, /* flag bit, label is allowed. */ - # EXPR_LABELED_bit, /* flag bit, just after a label. */ - # EXPR_FITEM_bit, /* symbol literal as FNAME. */ - # EXPR_MAX_STATE - # }; - def on_comment(body) - sexp = { type: :@comment, body: body.chomp, start: lineno, end: lineno } - - case RipperJS.lex_state_name(state) - when 'EXPR_END', 'EXPR_ARG|EXPR_LABELED', 'EXPR_ENDFN' - last_sexp.merge!(comments: [sexp]) - when 'EXPR_CMDARG', 'EXPR_END|EXPR_ENDARG', 'EXPR_ENDARG', 'EXPR_ARG', 'EXPR_FNAME|EXPR_FITEM', 'EXPR_CLASS', 'EXPR_END|EXPR_LABEL' - inline_comments << sexp - when 'EXPR_BEG|EXPR_LABEL', 'EXPR_MID' - inline_comments << sexp.merge!(break: true) - when 'EXPR_DOT' - last_sexp.merge!(comments: [sexp.merge!(break: true)]) - end - - sexp - end - - defined_events = private_instance_methods(false).grep(/\Aon_/) { $'.to_sym } - - (Ripper::PARSER_EVENTS - defined_events).each do |event| - define_method(:"on_#{event}") do |*body| - super(*body).tap do |sexp| - @last_sexp = sexp - next if inline_comments.empty? - - sexp[:comments] = inline_comments.reverse - @inline_comments = [] - end - end - end - end - - # Handles __END__ syntax, which allows individual scripts to keep content - # after the main ruby code that can be read through DATA. - module Ending - def initialize(source, *args) - super(source, *args) - @source = source - @ending = nil - end - - def self.prepended(base) - base.attr_reader :source, :ending - end - - private - - def on___end__(body) - @ending = super(source.split("\n")[lineno..-1].join("\n")) - end - - def on_program(*body) - super(*body).tap { |sexp| sexp[:body][0][:body] << ending if ending } - end - end - - # Adds the used quote type onto string nodes. - module Strings - private - - def on_tstring_end(quote) - last_sexp.merge!(quote: quote) - end - end -end - -class RipperJS < Ripper - private - - SCANNER_EVENTS.each do |event| - define_method(:"on_#{event}") do |body| - { type: :"@#{event}", body: body, start: lineno, end: lineno } - end - end - - PARSER_EVENTS.each do |event| - define_method(:"on_#{event}") do |*body| - min = body.map { |part| part.is_a?(Hash) ? part[:start] : lineno }.min - { type: event, body: body, start: min || lineno, end: lineno } - end - end - - prepend Layer::Lists - prepend Layer::StartLine - prepend Layer::InlineComments - prepend Layer::BlockComments - prepend Layer::Heredocs - prepend Layer::Encoding - prepend Layer::Ending - prepend Layer::Strings -end - -if $0 == __FILE__ - builder = RipperJS.new($stdin.read) - response = builder.parse - - if builder.error? - STDERR.puts 'Invalid ruby' - exit 1 - end - - puts JSON.fast_generate(response) -end diff --git a/src/ruby.js b/src/ruby.js deleted file mode 100644 index f3366669..00000000 --- a/src/ruby.js +++ /dev/null @@ -1,78 +0,0 @@ -const parse = require("./parse"); -const print = require("./print"); - -const pragmaPattern = /#\s*@(prettier|format)/; -const hasPragma = text => pragmaPattern.test(text); - -module.exports = { - languages: [{ - name: "Ruby", - parsers: ["ruby"], - extensions: [ - ".gemspec", - ".podspec", - ".rake", - ".rb", - ".ru" - ], - filenames: [ - ".irbrc", - ".pryrc", - "Capfile", - "Gemfile", - "Guardfile", - "Podfile", - "Rakefile" - ], - linguistLanguageId: 326, - vscodeLanguageIds: ["ruby"] - }], - parsers: { - ruby: { - parse, - astFormat: "ruby", - hasPragma - } - }, - printers: { - ruby: { - print - } - }, - options: { - addTrailingCommas: { - type: "boolean", - category: "Global", - default: false, - description: "Adds a trailing comma to array literals, hash literals, and method calls." - }, - inlineConditionals: { - type: "boolean", - category: "Global", - default: true, - description: "When it fits on one line, allows if and unless statements to use the modifier form." - }, - inlineLoops: { - type: "boolean", - category: "Global", - default: true, - description: "When it fits on one line, allows while and until statements to use the modifier form." - }, - preferHashLabels: { - type: "boolean", - category: "Global", - default: true, - description: "When possible, uses the shortened hash key syntax, as opposed to hash rockets." - }, - preferSingleQuotes: { - type: "boolean", - category: "Global", - default: true, - description: "When double quotes are not necessary for interpolation, prefers the use of single quotes for string literals." - } - }, - defaultOptions: { - printWidth: 80, - tabWidth: 2 - } -}; diff --git a/src/server.rb b/src/server.rb new file mode 100644 index 00000000..d5876cf7 --- /dev/null +++ b/src/server.rb @@ -0,0 +1,167 @@ +# frozen_string_literal: true + +require "bundler/setup" +require "json" +require "socket" + +require "syntax_tree" + +# Optional dependencies +%W[syntax_tree/rbs syntax_tree/haml prettier_print].each do |dep| + begin + require dep + rescue LoadError + end +end + +# First, require all of the plugins that the user specified. +ARGV.shift[/^--plugins=(.*)$/, 1] + .split(",") + .each { |plugin| require "syntax_tree/#{plugin}" } + +# Next, get the file where we should write our connection information. +connection_filepath = ARGV.shift + +# Make sure we trap these signals to be sure we get the quit command coming from +# the parent node process +quit = false +trap(:INT) { quit = true } +trap(:TERM) { quit = true } + +if Signal.list.key?("QUIT") && RUBY_ENGINE != "jruby" + trap(:QUIT) { quit = true } +end + +connection_information = + if Gem.win_platform? + # If we're on windows, we're going to start up a TCP server. The 0 here + # means to bind to some available port. + server = TCPServer.new(0) + address = server.local_address + + # Ensure that we close the server when this process exits. + at_exit { server.close } + + # Return the connection information. + { address: address.ip_address, port: address.ip_port } + else + # If we're not on windows, then we're going to assume we can use unix socket + # files (since they're faster than a TCP server). + filepath = "/tmp/prettier-ruby-parser-#{Process.pid}.sock" + server = UNIXServer.new(filepath) + + # Ensure that we close the server and delete the socket file when this + # process exits. + at_exit do + server.close + File.unlink(filepath) + end + + # Return the connection information. + { path: server.local_address.unix_path } + end + +# This is the actual listening thread that will be acting as our server. We have +# to start it in another thread in order to properly trap the signals in this +# parent thread. +listener = + Thread.new do + loop do + break if quit + + # Start up a new thread that will handle each successive connection. + Thread.new(server.accept_nonblock) do |socket| + request = JSON.parse(socket.read.force_encoding("UTF-8")) + source = request["source"] + + source.each_line do |line| + case line + when /^\s*#.+?coding/ + # If we've found an encoding comment, then we're going to take that + # into account and reclassify the encoding for the source. + encoding = Ripper.new(line).tap(&:parse).encoding + source = source.force_encoding(encoding) + break + when /^\s*#/ + # continue + else + break + end + end + + # At the moment, we're not going to support odd tabwidths. It's going to + # have to be a multiple of 2, because of the way that the prettyprint + # gem functions. So we're going to just use integer division here. + scalar = request["tabwidth"].to_i / 2 + genspace = ->(n) { " " * n * scalar } + + maxwidth = request["maxwidth"].to_i + response = + case request["parser"] + when "ruby" + formatter = + SyntaxTree::Formatter.new(source, [], maxwidth, "\n", &genspace) + SyntaxTree.parse(source).format(formatter) + formatter.flush + formatter.output.join + when "rbs" + formatter = + SyntaxTree::RBS::Formatter.new( + source, + [], + maxwidth, + "\n", + &genspace + ) + SyntaxTree::RBS.parse(source).format(formatter) + formatter.flush + formatter.output.join + when "haml" + formatter = + if defined?(SyntaxTree::Haml::Format::Formatter) + SyntaxTree::Haml::Format::Formatter.new( + source, + +"", + maxwidth, + "\n", + &genspace + ) + else + PrettierPrint.new(+"", maxwidth, "\n", &genspace) + end + + SyntaxTree::Haml.parse(source).format(formatter) + formatter.flush + formatter.output + end + + if response + socket.write(JSON.fast_generate(response.force_encoding("UTF-8"))) + else + socket.write("{ \"error\": true }") + end + rescue SyntaxTree::Parser::ParseError => error + loc = { start: { line: error.lineno, column: error.column } } + socket.write(JSON.fast_generate(error: error.message, loc: loc)) + rescue StandardError => error + begin + socket.write(JSON.fast_generate(error: error.message)) + rescue Errno::EPIPE + # Do nothing, the pipe has been closed by the parent process so we + # don't actually care about writing to it anymore. + end + ensure + socket.close + end + rescue IO::WaitReadable, Errno::EINTR + # Wait for select(2) to give us a connection that has content for 1 + # second. Otherwise timeout and continue on (so that we hit our + # "break if quit" pretty often). + IO.select([server], nil, nil, 1) + + retry unless quit + end + end + +File.write(connection_filepath, JSON.fast_generate(connection_information)) +listener.join diff --git a/src/utils.js b/src/utils.js deleted file mode 100644 index 310264c1..00000000 --- a/src/utils.js +++ /dev/null @@ -1,122 +0,0 @@ -const { breakParent, concat, hardline, lineSuffix, literalline } = require("prettier").doc.builders; - -const concatBody = (path, opts, print) => concat(path.map(print, "body")); - -const docLength = doc => { - if (doc.length) { - return doc.length; - } - - if (doc.parts) { - return doc.parts.reduce((sum, child) => sum + docLength(child), 0); - } - - return 0; -}; - -const empty = () => ""; - -const first = (path, opts, print) => path.call(print, "body", 0); - -const literal = value => () => value; - -const makeArgs = (path, opts, print, argsIndex) => { - let argNodes = path.getValue().body[argsIndex]; - const argPattern = [print, "body", argsIndex, "body"]; - - if (argNodes.type === "args_add_block") { - [argNodes] = argNodes.body; - argPattern.push(0, "body"); - } - - const args = path.call(print, "body", argsIndex); - const heredocs = []; - - argNodes.body.forEach((argNode, index) => { - let pattern; - let heredoc; - - if (argNode.type === "heredoc") { - pattern = [index, "body"]; - heredoc = argNode; - } else if (argNode.type === "string_literal" && argNode.body[0].type === "heredoc") { - pattern = [index, "body", 0, "body"]; - [heredoc] = argNode.body; - } else { - return; - } - - const content = path.map.apply(path, argPattern.slice().concat(pattern)); - heredocs.push(concat([literalline].concat(content).concat([heredoc.ending]))); - args[index] = heredoc.beging; - }); - - return { args, heredocs }; -}; - -const makeCall = (path, opts, print) => { - const operation = path.getValue().body[1]; - - if ([".", "&."].includes(operation)) { - return operation; - } - - return operation === "::" ? "." : path.call(print, "body", 1); -}; - -const makeList = (path, opts, print) => path.map(print, "body"); - -const prefix = value => (path, opts, print) => concat([ - value, - path.call(print, "body", 0) -]); - -const printComments = (printed, start, comments) => { - let node = printed; - - comments.forEach(comment => { - if (comment.start < start) { - node = concat([ - comment.break ? breakParent : "", - comment.body, - hardline, - node - ]); - } else { - node = concat([ - node, - comment.break ? breakParent : "", - lineSuffix(` ${comment.body}`) - ]); - } - }); - - return node; -}; - -const skipAssignIndent = node => ( - ["array", "hash", "heredoc", "regexp_literal"].includes(node.type) - || (node.type === "call" && skipAssignIndent(node.body[0])) - || (node.type === "string_literal" && node.body[0].type === "heredoc") -); - -const surround = (left, right) => (path, opts, print) => concat([ - left, - path.call(print, "body", 0), - right -]); - -module.exports = { - concatBody, - docLength, - empty, - first, - literal, - makeArgs, - makeCall, - makeList, - prefix, - printComments, - skipAssignIndent, - surround -}; diff --git a/test/cases/__snapshots__/alias.test.js.snap b/test/cases/__snapshots__/alias.test.js.snap deleted file mode 100644 index dda1108e..00000000 --- a/test/cases/__snapshots__/alias.test.js.snap +++ /dev/null @@ -1,29 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`alias.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Style/GlobalVars -class AliasTest < Minitest::Test - def test_plain_alias - assert_equal 'plain alias', foo - end - - def test_global_alias - $bar = 'global alias' - assert_equal 'global alias', $foo - end - - private - - def baz - 'plain alias' - end - - alias bar baz # inline comment - alias foo bar - alias $foo $bar -end -# rubocop:enable Style/GlobalVars -" -`; diff --git a/test/cases/__snapshots__/array.test.js.snap b/test/cases/__snapshots__/array.test.js.snap deleted file mode 100644 index 3cee252e..00000000 --- a/test/cases/__snapshots__/array.test.js.snap +++ /dev/null @@ -1,189 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`array.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class ArrayTest < Minitest::Test - def test_basics - assert_equal_join '', [] - assert_equal_join '1, 2, 3', [1, 2, 3] - assert_equal_join 'a, b, c', %w[a b c] - assert_equal_join 'a, b c, d', ['a', 'b c', 'd'] - assert_equal_join 'a, b, c', %i[a b c] - assert_equal_join 'a, b c, d', [:a, :'b c', :d] - end - - def test_literals - assert_equal_join 'a, b, c', %w[a b c] - assert_equal_join 'a, b, c', %i[a b c] - end - - # rubocop:disable Style/UnneededInterpolation - def test_string_arrays_with_interpolation - interp = 'b' - assert_equal_join 'a, b, c', ['a', \\"#{interp}\\", 'c'] - end - # rubocop:enable Style/UnneededInterpolation - - def test_literals_with_interpolation - foo = 'foo' - bar = 'bar' - baz = 'baz' - - assert_equal_join 'afooa, bbarb, cbazc', %W[a#{foo}a b#{bar}b c#{baz}c] - assert_equal_join 'afooa, bbarb, cbazc', %I[a#{foo}a b#{bar}b c#{baz}c] - end - - # rubocop:disable Lint/UnneededSplatExpansion - def test_splats - assert_equal_join '1, 2, 3, 4, 5, 6', [1, 2, *[3, 4], 5, 6] - end - # rubocop:enable Lint/UnneededSplatExpansion - - def test_long_elements - super_super_super_super_super_super_long = 'foo' - arr = [ - super_super_super_super_super_super_long, - super_super_super_super_super_super_long, - [super_super_super_super_super_super_long] - ] - - assert_equal_join('foo, foo, foo', arr) - end - - def test_reference - arr = %w[foo bar] - - assert_equal 'bar', arr[1] - end - - def test_reference_assignment - arr = %w[foo bar] - arr[1] = 'baz' - - assert_equal 'baz', arr[1] - end - - def test_comments_within_reference_assignment - arr = %w[foo bar] - arr[1] = [ - # abc - %w[abc] - ] - - assert_equal_join 'abc', arr[1] - end - - def test_dynamic_reference - arr = [1, 2, 3] - idx = 0 - - assert_equal 1, arr[idx] - end - - private - - def assert_equal_join(expected, object) - assert_equal expected, object.join(', ') - end - - def assert_equal_str(expected, object) - assert_equal expected, object.to_s - end -end -" -`; - -exports[`array.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -class ArrayTest < Minitest::Test - def test_basics - assert_equal_join '', [] - assert_equal_join '1, 2, 3', [1, 2, 3] - assert_equal_join 'a, b, c', %w[a b c] - assert_equal_join 'a, b c, d', ['a', 'b c', 'd'] - assert_equal_join 'a, b, c', %i[a b c] - assert_equal_join 'a, b c, d', [:a, :'b c', :d] - end - - def test_literals - assert_equal_join 'a, b, c', %w[a b c] - assert_equal_join 'a, b, c', %i[a b c] - end - - # rubocop:disable Style/UnneededInterpolation - def test_string_arrays_with_interpolation - interp = 'b' - assert_equal_join 'a, b, c', ['a', \\"#{interp}\\", 'c'] - end - # rubocop:enable Style/UnneededInterpolation - - def test_literals_with_interpolation - foo = 'foo' - bar = 'bar' - baz = 'baz' - - assert_equal_join 'afooa, bbarb, cbazc', %W[a#{foo}a b#{bar}b c#{baz}c] - assert_equal_join 'afooa, bbarb, cbazc', %I[a#{foo}a b#{bar}b c#{baz}c] - end - - # rubocop:disable Lint/UnneededSplatExpansion - def test_splats - assert_equal_join '1, 2, 3, 4, 5, 6', [1, 2, *[3, 4], 5, 6] - end - # rubocop:enable Lint/UnneededSplatExpansion - - def test_long_elements - super_super_super_super_super_super_long = 'foo' - arr = [ - super_super_super_super_super_super_long, - super_super_super_super_super_super_long, - [super_super_super_super_super_super_long], - ] - - assert_equal_join('foo, foo, foo', arr) - end - - def test_reference - arr = %w[foo bar] - - assert_equal 'bar', arr[1] - end - - def test_reference_assignment - arr = %w[foo bar] - arr[1] = 'baz' - - assert_equal 'baz', arr[1] - end - - def test_comments_within_reference_assignment - arr = %w[foo bar] - arr[1] = [ - # abc - %w[abc], - ] - - assert_equal_join 'abc', arr[1] - end - - def test_dynamic_reference - arr = [1, 2, 3] - idx = 0 - - assert_equal 1, arr[idx] - end - - private - - def assert_equal_join(expected, object) - assert_equal expected, object.join(', ') - end - - def assert_equal_str(expected, object) - assert_equal expected, object.to_s - end -end -" -`; diff --git a/test/cases/__snapshots__/assign.test.js.snap b/test/cases/__snapshots__/assign.test.js.snap deleted file mode 100644 index f291c3ad..00000000 --- a/test/cases/__snapshots__/assign.test.js.snap +++ /dev/null @@ -1,169 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`assign.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UselessAssignment, Style/ParallelAssignment -# rubocop:disable Metrics/MethodLength -# rubocop:disable Metrics/AbcSize -# rubocop:disable Metrics/LineLength -# rubocop:disable Metrics/ClassLength - -class AssignTest < Minitest::Test - def test_assignment - a = 1 - assert_equal 1, a - - a = - begin - 2 - end - assert_equal 2, a - end - - def test_parallel_assignment - a, b, c = [1, 2, 3] - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - a = 1, 2, 3 - assert_equal [1, 2, 3], a - - a, b, c = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - a, b, c = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - a, b, c = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - a, b, c = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - end - - def test_assign_with_splat_operator - a, *b = 1, 2, 3 - assert_equal 1, a - assert_equal [2, 3], b - - a, *b, c, d = 1, 2, 3 - assert_equal 1, a - assert_equal [], b - assert_equal 2, c - assert_equal 3, d - - a, * = 1, 2, 3 - assert_equal 1, a - - a = *a - assert_equal [1], a - - (a, b), c = [1, 2], 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - * = [1, 2, 3] - - *, a = [1, 2, 3] - assert_equal 3, a - end - - def test_or_equals_operator - a = 2 - a ||= 1 - assert_equal 2, a - end - - def test_long_variable_assignment - super_super_super_super_super_long = 'bar' - super_super_super_long, super_super_super_long, super_super_super_long = - super_super_super_super_super_long, - super_super_super_super_super_long, - super_super_super_super_super_long - assert_equal super_super_super_long, 'bar' - - a = 2 - a ||= - super_super_super_super_super_super_super_super_super_super_super_super_long - assert_equal 2, a - - super_super_super_super_super_super_super_super_super_super_super_long = - 'foo' - a = [ - super_super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_super_long - ] - - assert_equal %w[foo foo foo], a - end - - def test_assign_hash - super_super_super_super_super_super_super_super_super_super_long = 'foo' - - hash = { - a: super_super_super_super_super_super_super_super_super_super_long, - b: super_super_super_super_super_super_super_super_super_super_long, - c: super_super_super_super_super_super_super_super_super_super_long - } - - assert_equal({ a: 'foo', b: 'foo', c: 'foo' }, hash) - end - - def test_assign_with_sort - # rubocop:disable Lint/UnneededCopDisableDirective - # rubocop:disable Layout/MultilineMethodCallIndentation - super_super_super_super_long = 'baz' - - arr = [super_super_super_super_long, super_super_super_super_long].sort - assert_equal %w[baz baz], arr - - arr = { - a: super_super_super_super_long, b: super_super_super_super_long - }.sort - .to_h - assert_equal({ a: 'baz', b: 'baz' }, arr) - - # rubocop:enable Layout/MultilineMethodCallIndentation - # rubocop:enable Lint/UnneededCopDisableDirective - end - - def test_setter_methods - a = Struct.new(:a).new - - a.a = 1 - assert_equal 1, a.a - - super_super_super_long = - Struct.new(:super_super_super_super_super_super_super_long).new - - super_super_super_super_super_super_super_super_super_super_super_long = 1 - - super_super_super_long.super_super_super_super_super_super_super_long = - super_super_super_super_super_super_super_super_super_super_super_long - - assert_equal( - super_super_super_long.super_super_super_super_super_super_super_long, - 1 - ) - end -end - -# rubocop:enable Lint/UselessAssignment, Style/ParallelAssignment -# rubocop:enable Metrics/MethodLength -# rubocop:enable Metrics/AbcSize -# rubocop:enable Metrics/LineLength -# rubocop:enable Metrics/ClassLength -" -`; diff --git a/test/cases/__snapshots__/binary.test.js.snap b/test/cases/__snapshots__/binary.test.js.snap deleted file mode 100644 index 101396e5..00000000 --- a/test/cases/__snapshots__/binary.test.js.snap +++ /dev/null @@ -1,24 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`binary.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class BinaryTest < Minitest::Test - def test_unbroken - value = true - - assert(value && value && value) - end - - def test_broken - super_super_super_super_super_long = true - - assert( - super_super_super_super_super_long && - super_super_super_super_super_long && - super_super_super_super_super_long - ) - end -end -" -`; diff --git a/test/cases/__snapshots__/blocks.test.js.snap b/test/cases/__snapshots__/blocks.test.js.snap deleted file mode 100644 index 118f8dc1..00000000 --- a/test/cases/__snapshots__/blocks.test.js.snap +++ /dev/null @@ -1,120 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`blocks.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UnusedBlockArgument - -loop { 1 } - -loop { 1 } - -loop do - # foobar -end - -port ENV.fetch('PORT') { 3000 } - -test 'foobar' do -end - -te.st 'foobar' do -end - -test 'foobar' do - foobar -end - -te.st 'foobar' do - foobar -end - -test 'foobar', &:to_s - -te.st 'foobar', &:to_s - -loop do - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -loop { super_super_super_super_super_super_super_super_super_super_super_long } - -loop { |i| 1 } - -loop { |i; j| 1 } - -loop { |i| i } - -loop { |*| i } - -loop { |(a, b)| i } - -loop { |a, (b, c), d, *e| i } - -loop do |i| - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -loop { |i| super_super_super_super_super_super_super_super_super_super_long } - -# rubocop:disable Metrics/LineLength -define_method :long_method_name_that_forces_overflow do |_some_long_argument_that_overflows = Time.now, _other_arg = nil| -end -# rubocop:enable Metrics/LineLength - -some_method.each do |foo| - bar - baz -end.to_i - -[ - super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_long -].to_s - -{ - a: 'super_super_super_super_super_super_super_super_super_super_long', - b: 'super_super_super_super_super_super_super_super_super_super_long' -}.to_s - -loop(&:to_s) - -loop(&:to_s) - -loop do |i| - i.to_s - i.next -end - -loop { |i| i.to_s :db } - -loop { |i, j| i.to_s } - -[1, 2, 3].each do |i| - p i -end - -def change - change_table :foo do - column :bar - end -end - -foo 'foo', &:to_s - -target.method object.map do |arg| - arg * 2 -end - -# from ruby test/ruby/test_call.rb -assert_nil( - ( - 'a'.sub! 'b' do - end&.foo do - end - ) -) - -# rubocop:enable Lint/UnusedBlockArgument -" -`; diff --git a/test/cases/__snapshots__/break.test.js.snap b/test/cases/__snapshots__/break.test.js.snap deleted file mode 100644 index 89dc4e0f..00000000 --- a/test/cases/__snapshots__/break.test.js.snap +++ /dev/null @@ -1,14 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`break.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -[].each { break } - -[].each { break 1 } - -[].each { break 1 } - -[].each { break 1, 2 } -" -`; diff --git a/test/cases/__snapshots__/case.test.js.snap b/test/cases/__snapshots__/case.test.js.snap deleted file mode 100644 index 747356a5..00000000 --- a/test/cases/__snapshots__/case.test.js.snap +++ /dev/null @@ -1,45 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`case.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/EmptyWhen, Style/EmptyCaseCondition - -case -when a - 1 -end - -case a -when b - 1 -end - -case a -when b, c - 1 -end - -case a -when b -when c - 1 -end - -case a -when b - 1 -when c - 2 -end - -case a -when b - 1 -else - 2 -end - -# rubocop:enable Lint/EmptyWhen, Style/EmptyCaseCondition -" -`; diff --git a/test/cases/__snapshots__/class.test.js.snap b/test/cases/__snapshots__/class.test.js.snap deleted file mode 100644 index 4d5d3cce..00000000 --- a/test/cases/__snapshots__/class.test.js.snap +++ /dev/null @@ -1,74 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`class.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -module Pret - module Tier - # object documentation - class Object; end - - # second object - # documentation - class Object; end - - # third object - # documentation - class Object - attr_accessor :foo - end - - class Object < BasicObject; end - - class Object < BasicObject; end - - class Object < BasicObject - # inside class documentation - attr_accessor :bar - end - - class SuperSuperSuperSuperSuperSuperSuperSuperSuperSuperSuperLongClassName - end - - module SuperSuperSuperSuperSuperSuperSuperSuperSuperSuperSuperLongModName - end - - class << self - # method documentation - def method1; end - - def method2; end - - def method3; end - - def method_with_a_long_name1; end - - def method_with_a_long_name2; end - - def method_with_a_long_name3; end - - undef method1 - undef method2, method3 - undef method_with_a_long_name1, - method_with_a_long_name2, - method_with_a_long_name3 - end - - module Prettier; end - - module Prettier; end - - module Prettier - # inside module documentation - attr_accessor :foo - end - end -end - -Pret::Tier::Object # rubocop:disable Lint/Void -Pret::TIER = 'config'.to_s - -::Pret::Tier::Object # rubocop:disable Lint/Void -::PRET = 'config'.to_s -" -`; diff --git a/test/cases/__snapshots__/comments.test.js.snap b/test/cases/__snapshots__/comments.test.js.snap deleted file mode 100644 index 3484fed3..00000000 --- a/test/cases/__snapshots__/comments.test.js.snap +++ /dev/null @@ -1,147 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`comments.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# this is a comment at -# the beginning of the file -# rubocop:disable Lint/Void - -loop do - # this is the only statement - # inside this loop -end - -loop do - # this is the first statement - # inside this loop - foo -end - -loop do - foo - # this is the last statement - # inside this loop -end - -def foo - # these are the only statements - # inside this method -end - -class Foo - # these are the only statements - # inside this class -end - -module Foo - # these are the only statements - # inside this module -end - -module Foo - class Foo - def foo - # this comment is inside a method - end - - def bar - print message # this is an inline comment - end - - def self.foo - # this comment is inside a self method - end - end -end - -foo # this is an inline comment -bar # this is another inline comment - -foo 'bar' # this is an inline comment - -[ - # these are comments - # inside of an array - foo, - # inside of an array - bar -] - -{ - # these are comments - foo: 'bar', - # inside of a hash - bar: 'baz' -} - -foo # inline comment inside of a dot - .bar - -Foo.where(foo: bar, bar: baz).to_a.find do |foo| - # This is a comment - foo.foo == bar.foo -end - -if foo - # this is a comment in an if - bar -end - -unless foo - # this is a comment in an unless - bar -end - -while foo - # this is a comment at the beginning of a while - bar -end - -while foo - bar - # this is a comment at the end of a while -end - -until foo - # this is a comment at the beginning of a until - bar -end - -until foo - bar - # this is a comment at the end of a until -end - -case foo -when bar - # this is a comment at the beginning of a when - 1 -when baz - 2 - # this is a comment at the end of a when -end - -begin - # comment at the beginning of a begin - 1 -rescue StandardError - # comment at the beginning of a rescue - 2 -ensure - # comment at the end of a rescue - 3 -end - -# rubocop:enable Lint/Void -# this is a comment -# at the end of the file - -__END__ - /‾‾‾‾‾\\\\ /‾‾‾‾‾\\\\ /‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾/ /‾‾‾‾‾\\\\ - / /‾‾/ / / /‾‾/ / / /‾‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ / /‾‾‾ / /‾‾/ / - / ‾‾‾ / / ‾‾‾_/ / _‾/ / / / / / / / _‾/ / ‾‾‾_/ - / /‾‾‾‾‾ / /‾\\\\ \\\\ / /__ / / / / __/ /_ / /__ / /‾\\\\ \\\\ -/_/ /_/ /_/ /____/ /_/ /_/ /_____/ /____/ /_/ /_/ -" -`; diff --git a/test/cases/__snapshots__/conditionals.test.js.snap b/test/cases/__snapshots__/conditionals.test.js.snap deleted file mode 100644 index 6e9c60fd..00000000 --- a/test/cases/__snapshots__/conditionals.test.js.snap +++ /dev/null @@ -1,239 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`conditionals.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -if a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/Not, Style/NegatedIf, Lint/EmptyExpression -b if not a - -# from ruby test/ruby/test_not.rb -assert_equal(true, (not ())) -# rubocop:enable Style/Not, Style/NegatedIf, Lint/EmptyExpression - -if a - break # comment -end - -if a - -else - b -end - -if a - 1 -elsif b - 2 -end - -if a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -if a - 1 -elsif b - 2 -elsif c - 3 -else - 4 -end - -unless a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/UnlessElse -unless a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end -# rubocop:enable Style/UnlessElse - -1 if a - -if super_super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -1 unless a - -unless super_super_super_super_super_super_super_super_super_super_super_suplong - 1 -end - -a ? 1 : 2 - -a ? 2 : 1 - -a ? 1 : 2 -if a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -if a - b 1 -else - b(2) -end - -if a - b(1) -else - b 2 -end - -a b do - if a - a 'foo' - else - b - end -end - -if Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 1 -elsif Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 2 -end - -unless Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 1 -end -" -`; - -exports[`conditionals.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -if a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/Not, Style/NegatedIf, Lint/EmptyExpression -if not a - b -end - -# from ruby test/ruby/test_not.rb -assert_equal(true, (not ())) -# rubocop:enable Style/Not, Style/NegatedIf, Lint/EmptyExpression - -if a - break # comment -end - -if a - -else - b -end - -if a - 1 -elsif b - 2 -end - -if a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -if a - 1 -elsif b - 2 -elsif c - 3 -else - 4 -end - -unless a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/UnlessElse -unless a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end -# rubocop:enable Style/UnlessElse - -if a - 1 -end - -if super_super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -unless a - 1 -end - -unless super_super_super_super_super_super_super_super_super_super_super_suplong - 1 -end - -a ? 1 : 2 - -a ? 2 : 1 - -a ? 1 : 2 -if a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -if a - b 1 -else - b(2) -end - -if a - b(1) -else - b 2 -end - -a b do - if a - a 'foo' - else - b - end -end - -if Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 1 -elsif Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 2 -end - -unless Some::Constant - .super_super_super_super_super_super_super_super_super_super_long - 1 -end -" -`; diff --git a/test/cases/__snapshots__/defined.test.js.snap b/test/cases/__snapshots__/defined.test.js.snap deleted file mode 100644 index 6499bf66..00000000 --- a/test/cases/__snapshots__/defined.test.js.snap +++ /dev/null @@ -1,28 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`defined.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/Void - -defined?(a) # first - -defined?(a) # second - -defined?( - super_super_super_super_super_super_super_super_super_super_super_super_long -) - -defined?( - super_super_super_super_super_super_super_super_super_super_super_super_long -) - -defined?( - super_super_super_super_super_super_super_super_super_super_super_super_long -) - -defined?(a) # third - -# rubocop:enable Lint/Void -" -`; diff --git a/test/cases/__snapshots__/embdoc.test.js.snap b/test/cases/__snapshots__/embdoc.test.js.snap deleted file mode 100644 index 8c37b48e..00000000 --- a/test/cases/__snapshots__/embdoc.test.js.snap +++ /dev/null @@ -1,34 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`embdoc.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Style/BlockComments - -=begin -this is - -some really - -long documentation -that is contained -in an embdoc -=end - -class Foo -=begin -this is an embdoc inside a class -=end -end - -module Foo - class Foo -=begin -this is an embdoc even more indented -=end - end -end - -# rubocop:enable Style/BlockComments -" -`; diff --git a/test/cases/__snapshots__/encoding.test.js.snap b/test/cases/__snapshots__/encoding.test.js.snap deleted file mode 100644 index 2bd13bdb..00000000 --- a/test/cases/__snapshots__/encoding.test.js.snap +++ /dev/null @@ -1,16 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`encoding.rb matches expected output 1`] = ` -"# -*- encoding: binary -*- -# frozen_string_literal: true - -# rubocop:disable Lint/Void, Style/AsciiComments - -# il était -:il_était -'ひらがな' -/ひらがな/ - -# rubocop:enable Lint/Void, Style/AsciiComments -" -`; diff --git a/test/cases/__snapshots__/hash.test.js.snap b/test/cases/__snapshots__/hash.test.js.snap deleted file mode 100644 index ddd79702..00000000 --- a/test/cases/__snapshots__/hash.test.js.snap +++ /dev/null @@ -1,87 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`hash.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/Void - -{} - -{ a: 'a', b: 'b', c: 'c' } - -{ a: 'a', b: 'b', c: 'c' } - -{ Foo => 1, Bar => 2 } - -{ - super_super_super_super_super_super_super_super_long: - super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_long: { - super_super_super_super_super_super_super_super_long: - super_super_super_super_super_super_super_super_long - } -} - -foo abc: true # some comment - -foobar alpha: alpha, - beta: beta, - gamma: gamma, - delta: delta, - epsilon: epsilon, - zeta: zeta -foobar( - alpha: alpha, - beta: beta, - gamma: gamma, - delta: delta, - epsilon: epsilon, - zeta: zeta -) - -# rubocop:enable Lint/Void -" -`; - -exports[`hash.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/Void - -{} - -{ :a => 'a', :b => 'b', :c => 'c' } - -{ :a => 'a', :b => 'b', :c => 'c' } - -{ Foo => 1, Bar => 2 } - -{ - :super_super_super_super_super_super_super_super_long => - super_super_super_super_super_super_super_super_long, - :super_super_super_super_super_super_super_super_super_long => { - :super_super_super_super_super_super_super_super_long => - super_super_super_super_super_super_super_super_long - } -} - -foo :abc => true # some comment - -foobar :alpha => alpha, - :beta => beta, - :gamma => gamma, - :delta => delta, - :epsilon => epsilon, - :zeta => zeta -foobar( - :alpha => alpha, - :beta => beta, - :gamma => gamma, - :delta => delta, - :epsilon => epsilon, - :zeta => zeta -) - -# rubocop:enable Lint/Void -" -`; diff --git a/test/cases/__snapshots__/hooks.test.js.snap b/test/cases/__snapshots__/hooks.test.js.snap deleted file mode 100644 index 2847409c..00000000 --- a/test/cases/__snapshots__/hooks.test.js.snap +++ /dev/null @@ -1,34 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`hooks.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Style/BeginBlock, Style/EndBlock - -BEGIN { p 'begin' } - -BEGIN { p 'begin' } - -BEGIN { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -BEGIN { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -END { p 'end' } - -END { p 'end' } - -END { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -END { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -# rubocop:enable Style/BeginBlock, Style/EndBlock -" -`; diff --git a/test/cases/__snapshots__/kwargs.test.js.snap b/test/cases/__snapshots__/kwargs.test.js.snap deleted file mode 100644 index ee0d444b..00000000 --- a/test/cases/__snapshots__/kwargs.test.js.snap +++ /dev/null @@ -1,21 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`kwargs.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class KwargsTest < Minitest::Test - def test_kwargs - assert_equal 10, add(alpha: 1, beta: 2, gamma: 3, delta: 4) - - args = { alpha: 1, beta: 2, gamma: 3 } - assert_equal 10, add(**args, delta: 4) - end - - private - - def add(alpha:, beta:, gamma: 1, delta: 2) - alpha + beta + gamma + delta - end -end -" -`; diff --git a/test/cases/__snapshots__/lambda.test.js.snap b/test/cases/__snapshots__/lambda.test.js.snap deleted file mode 100644 index 5104e7de..00000000 --- a/test/cases/__snapshots__/lambda.test.js.snap +++ /dev/null @@ -1,49 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`lambda.rb matches expected output 1`] = ` -"# frozen_string_literal: true - --> { 1 } - -->(a, b, c) { a + b + c } - -lambda do - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -lambda do |a, b, c| - a + b + c + super_super_super_super_super_super_super_super_super_long -end - -a.call(1, 2, 3) - -a.call(1, 2, 3) - -a[] - -a[1, 2, 3] - -->(a) { a } - --> { 1 } - -command :foobar, ->(argument) { argument + argument } -comm.and :foobar, ->(argument) { argument + argument } - -command :fooooooooooooobaaaaaaarrrrr, - lambda { |argument| - argument + argument + argument + argument + argument + argument - } -comm.and :fooooooooooooobaaaaaaarrrrr, - lambda { |argument| - argument + argument + argument + argument + argument + argument - } - -# rubocop:disable Metrics/LineLength -command :fooooooooooooobaaaaaaarrrrr, - lambda { |_fooooooooooooobaaaaaaarrrrr1, _fooooooooooooobaaaaaaarrrrr2, _fooooooooooooobaaaaaaarrrrr3| - true - } -# rubocop:enable Metrics/LineLength -" -`; diff --git a/test/cases/__snapshots__/layout.test.js.snap b/test/cases/__snapshots__/layout.test.js.snap deleted file mode 100644 index 61dff680..00000000 --- a/test/cases/__snapshots__/layout.test.js.snap +++ /dev/null @@ -1,28 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`layout.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/Void - -1 - -def foobar - 2 - - 3 - 4 - 5 - - 6 -end - -7 -8 -9 - -10 - -# rubocop:enable Lint/Void -" -`; diff --git a/test/cases/__snapshots__/method.test.js.snap b/test/cases/__snapshots__/method.test.js.snap deleted file mode 100644 index a9032016..00000000 --- a/test/cases/__snapshots__/method.test.js.snap +++ /dev/null @@ -1,299 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`method.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:disable Metrics/ParameterLists - -def foo; end - -def foo(); end - -def foo(alpha); end - -def foo(alpha); end - -def self.foo; end - -def self.foo(); end - -def self.foo(alpha); end - -def self.foo(alpha); end - -def foo(alpha, beta, *gamma, delta, epsilon:, zeta:, eta: 1, **theta, &block) - 'what' -end - -def foo( - alpha:, - beta:, - gamma:, - delta:, - epsilon:, - zeta:, - eta:, - theta:, - iota:, - kappa:, - lambda: -) - 'what' -end - -def foo(alpha) - 1 -end - -def foo(*); end - -def foo(**); end - -foo - -foo(1) -foo(1, 2) -foo(1, 2, *abc) -foo(1, 2, *abc, 3, 4) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - &block -) - -foo aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -foo.foo aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii - -Foo::Bar::Baz.qux aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -Foo::Bar::Baz.qux aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii, - &block - -foo(*bar) -foo(**baz) -foo(&block) - -foo(*bar, &block) -foo(**baz, &block) -foo(*bar, **baz, &block) - -foo(h: 1, **bar) -foo(**bar, h: 1) -foo(h: 1, **bar, i: 2) - -Foo.foo -foo&.foo - -# rubocop:enable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:enable Metrics/ParameterLists -" -`; - -exports[`method.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:disable Metrics/ParameterLists - -def foo; end - -def foo(); end - -def foo(alpha); end - -def foo(alpha); end - -def self.foo; end - -def self.foo(); end - -def self.foo(alpha); end - -def self.foo(alpha); end - -def foo(alpha, beta, *gamma, delta, epsilon:, zeta:, eta: 1, **theta, &block) - 'what' -end - -def foo( - alpha:, - beta:, - gamma:, - delta:, - epsilon:, - zeta:, - eta:, - theta:, - iota:, - kappa:, - lambda: -) - 'what' -end - -def foo(alpha) - 1 -end - -def foo(*); end - -def foo(**); end - -foo - -foo(1) -foo(1, 2) -foo(1, 2, *abc) -foo(1, 2, *abc, 3, 4) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii, -) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii, -) -foo( - aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - &block -) - -foo aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -foo.foo aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii - -Foo::Bar::Baz.qux aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii -Foo::Bar::Baz.qux aaaaaaa, - bbbbbbb, - ccccccc, - ddddddd, - eeeeeee, - fffffff, - ggggggg, - hhhhhhh, - iiiiiii, - &block - -foo(*bar) -foo(**baz) -foo(&block) - -foo(*bar, &block) -foo(**baz, &block) -foo(*bar, **baz, &block) - -foo(h: 1, **bar) -foo(**bar, h: 1) -foo(h: 1, **bar, i: 2) - -Foo.foo -foo&.foo - -# rubocop:enable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:enable Metrics/ParameterLists -" -`; diff --git a/test/cases/__snapshots__/next.test.js.snap b/test/cases/__snapshots__/next.test.js.snap deleted file mode 100644 index 23618036..00000000 --- a/test/cases/__snapshots__/next.test.js.snap +++ /dev/null @@ -1,32 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`next.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class NextTest < Minitest::Test - def test_no_args - result = [1, 2, 3].map { next } - - assert_equal [nil, nil, nil], result - end - - def test_one_arg_no_parens - result = [1, 2, 3].map { next 1 } - - assert_equal [1, 1, 1], result - end - - def test_one_arg_with_parens - result = [1, 2, 3].map { next 1 } - - assert_equal [1, 1, 1], result - end - - def test_multi_args_no_parens - result = [1, 2, 3].map { next 1, 2 } - - assert_equal [[1, 2], [1, 2], [1, 2]], result - end -end -" -`; diff --git a/test/cases/__snapshots__/numbers.test.js.snap b/test/cases/__snapshots__/numbers.test.js.snap deleted file mode 100644 index 12f4547b..00000000 --- a/test/cases/__snapshots__/numbers.test.js.snap +++ /dev/null @@ -1,34 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`numbers.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class NumbersTest < Minitest::Test - def test_numbers - assert_equal_str '123', 123 - assert_equal_str '-123', -123 - assert_equal_str '1123', 1_123 - assert_equal_str '-543', -543 - assert_equal_str '123456789123456789', 123_456_789_123_456_789 - end - - def test_floats - assert_equal_str '123.45', 123.45 - assert_equal_str '0.0012', 1.2e-3 - end - - def test_bases - assert_equal_str '43707', 0xaabb - assert_equal_str '255', 0o377 - assert_equal_str '-10', -0b1010 - assert_equal_str '9', 0b001_001 - end - - private - - def assert_equal_str(expected, value) - assert_equal expected, value.to_s - end -end -" -`; diff --git a/test/cases/__snapshots__/ranges.test.js.snap b/test/cases/__snapshots__/ranges.test.js.snap deleted file mode 100644 index ea1b2e48..00000000 --- a/test/cases/__snapshots__/ranges.test.js.snap +++ /dev/null @@ -1,13 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`ranges.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UselessAssignment - -dot2 = 1..2 # dot2 -dot3 = 3...4 # dot3 - -# rubocop:enable Lint/UselessAssignment -" -`; diff --git a/test/cases/__snapshots__/regexp.test.js.snap b/test/cases/__snapshots__/regexp.test.js.snap deleted file mode 100644 index e2c8fe45..00000000 --- a/test/cases/__snapshots__/regexp.test.js.snap +++ /dev/null @@ -1,81 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`regexp.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -class RegexpTest < Minitest::Test - def test_default - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_braces - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_braces_with_slashes - regexp = %r{a/b/c} - - assert_match regexp, 'a/b/c/d/e' - end - - def test_slashes - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_brackets - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_parens - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_interpolation - inter = 'b' - regexp = /a#{inter}c/ - - assert_match regexp, 'abcde' - end - - def test_modifier - regexp = /abc/i - - assert_match regexp, 'ABCDE' - end - - def test_brace_modifier - regexp = /abc/i - - assert_match regexp, 'ABCDE' - end - - def test_global_interpolation - 'foo' =~ /foo/ - regexp = /#{$&}/ - - assert_match regexp, 'foobar' - end - - def test_float - float_pat = /\\\\A - [[:digit:]]+ # 1 or more digits before the decimal point - (\\\\. # Decimal point - [[:digit:]]+ # 1 or more digits after the decimal point - )? # The decimal point and following digits are optional - \\\\Z/x - - assert_match float_pat, '12.56' - end -end -" -`; diff --git a/test/cases/__snapshots__/rescue.test.js.snap b/test/cases/__snapshots__/rescue.test.js.snap deleted file mode 100644 index 95ec6d9b..00000000 --- a/test/cases/__snapshots__/rescue.test.js.snap +++ /dev/null @@ -1,40 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`rescue.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -begin - 1 -rescue ArgumentError - retry -rescue NoMethodError => exception - puts exception - redo -rescue SyntaxError, NoMethodError - 2 -rescue SomeSuperSuperLongError, - SomeOtherSuperSuperLongError, - OneLastSuperLongError - 3 -rescue StandardError - 4 -else - 5 -ensure - 6 -end - -begin - a -rescue StandardError - nil -end - -# from ruby spec/ruby/language/rescue_spec.rb -def foo - a -rescue A, *B => e - e -end -" -`; diff --git a/test/cases/__snapshots__/return.test.js.snap b/test/cases/__snapshots__/return.test.js.snap deleted file mode 100644 index 87e4774d..00000000 --- a/test/cases/__snapshots__/return.test.js.snap +++ /dev/null @@ -1,32 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`return.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UnneededCopDisableDirective -# rubocop:disable Style/GuardClause, Style/RedundantReturn - -def foo - return if a -end - -def bar - return 1 if a -end - -def baz - return 1 if a -end - -def qux - return 1, 2 if a -end - -def qax - return foo :bar if a -end - -# rubocop:enable Style/GuardClause, Style/RedundantReturn -# rubocop:enable Lint/UnneededCopDisableDirective -" -`; diff --git a/test/cases/__snapshots__/strings.test.js.snap b/test/cases/__snapshots__/strings.test.js.snap deleted file mode 100644 index 7eb6ee29..00000000 --- a/test/cases/__snapshots__/strings.test.js.snap +++ /dev/null @@ -1,343 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`strings.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UnneededCopDisableDirective - -# rubocop:disable Layout/ClosingParenthesisIndentation -# rubocop:disable Layout/SpaceInsideStringInterpolation -# rubocop:disable Lint/InterpolationCheck -# rubocop:disable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:disable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:disable Style/StringLiteralsInInterpolation -# rubocop:disable Style/UnneededInterpolation - -'a' # these are CHARs -?\\\\C-a -?\\\\M-a -?\\\\M-\\\\C-a - -'' - -'abc' - -\\"abc's\\" - -'abc' - -\\"abc\\\\n\\" - -'\\\\n' -\\"\\\\n\\" -'\\\\x0' -\\"\\\\x0\\" -'#{\\"\\\\n\\"}' -\\"#{\\"\\\\n\\"}\\" -\\"#{'\\\\n'}\\" -\\"#{'\\\\n'}#{\\"\\\\n\\"}\\" -\\"#{\\"\\\\n#{'\\\\n'}#{\\"\\\\n\\"}\\\\n\\"}#{'\\\\n'}\\" - -\\"\\\\M-\\\\C-a\\" - -\\"abc #{super} abc\\" - -\\"#{abc} abc\\" - -\\"{\\\\\\"abc\\\\\\": \\\\\\"foo\\\\nbar\\\\\\"}\\" - -# rubocop:disable Style/Semicolon -\\"abc #{foo; bar} abc\\" -# rubocop:enable Style/Semicolon - -\\"abc #{de} fghi #{jkl} mno\\" - -'abc' \\\\ - 'def' \\\\ - 'ghi' - -\\"abc #{\\"abc #{abc} abc\\"} abc\\" - -{ 'a' => 1 } - -{ \\"a #{a}\\" => 1 } - -:\\"abc#{abc}abc\\" -:'abc#{abc}abc' - -\`abc\` -\`super_super_super_super_super_super_super_super_super_super_super_super_s_long\` -\` - super_super_super_super_super_super_super_super_super_super_super_super_s_long -\`.to_s - -<<-HERE -This is a straight heredoc! -HERE - -<<-HERE -This is another straight heredoc, this time with interpolation! -#{interpolation} -So interpolated right now. -HERE - -abc = <<-HERE -This is a straight heredoc on an assign! -HERE - -<<-PARENT -This is a straight heredoc! -#{<<-CHILD -Why do I do this -CHILD -} -PARENT - -<<~HERE - This is a squiggly heredoc! -HERE - -<<~HERE - This is another squiggly heredoc, this time with interpolation! - #{interpolation} - So interpolated right now. -HERE - -abc = <<~HERE - This is a squiggly heredoc on an assign! -HERE - -<<~PARENT - This is a squiggly heredoc! - #{<<~CHILD - Why do I do this - CHILD -} -PARENT - -<<-GRAND -#{'interpolated'} -<<~PARENT - #{'more interpolated'} - <<-CHILD - #{'what is going on'} - CHILD - #{'more interpolated'} -PARENT -#{'interpolated'} -GRAND - -'abc \\"abc\\" abc' - -foo_bar 1, 2, 3, <<-HERE - baz -HERE - -foo.bar 1, 2, 3, <<-HERE - baz -HERE - -foo_bar(1, 2, 3, <<-HERE) - baz -HERE - -foo_bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo.bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo_bar(1, 2, 3, <<-HERE, <<-THERE) - here -HERE - there -THERE - -# rubocop:enable Layout/ClosingParenthesisIndentation -# rubocop:enable Layout/SpaceInsideStringInterpolation -# rubocop:enable Lint/InterpolationCheck -# rubocop:enable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:enable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:enable Style/StringLiteralsInInterpolation -# rubocop:enable Style/UnneededInterpolation - -# rubocop:enable Lint/UnneededCopDisableDirective -" -`; - -exports[`strings.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -# rubocop:disable Lint/UnneededCopDisableDirective - -# rubocop:disable Layout/ClosingParenthesisIndentation -# rubocop:disable Layout/SpaceInsideStringInterpolation -# rubocop:disable Lint/InterpolationCheck -# rubocop:disable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:disable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:disable Style/StringLiteralsInInterpolation -# rubocop:disable Style/UnneededInterpolation - -\\"a\\" # these are CHARs -?\\\\C-a -?\\\\M-a -?\\\\M-\\\\C-a - -\\"\\" - -\\"abc\\" - -\\"abc's\\" - -\\"abc\\" - -\\"abc\\\\n\\" - -'\\\\n' -\\"\\\\n\\" -'\\\\x0' -\\"\\\\x0\\" -'#{\\"\\\\n\\"}' -\\"#{\\"\\\\n\\"}\\" -\\"#{'\\\\n'}\\" -\\"#{'\\\\n'}#{\\"\\\\n\\"}\\" -\\"#{\\"\\\\n#{'\\\\n'}#{\\"\\\\n\\"}\\\\n\\"}#{'\\\\n'}\\" - -\\"\\\\M-\\\\C-a\\" - -\\"abc #{super} abc\\" - -\\"#{abc} abc\\" - -\\"{\\\\\\"abc\\\\\\": \\\\\\"foo\\\\nbar\\\\\\"}\\" - -# rubocop:disable Style/Semicolon -\\"abc #{foo; bar} abc\\" -# rubocop:enable Style/Semicolon - -\\"abc #{de} fghi #{jkl} mno\\" - -\\"abc\\" \\\\ - \\"def\\" \\\\ - \\"ghi\\" - -\\"abc #{\\"abc #{abc} abc\\"} abc\\" - -{ \\"a\\" => 1 } - -{ \\"a #{a}\\" => 1 } - -:\\"abc#{abc}abc\\" -:'abc#{abc}abc' - -\`abc\` -\`super_super_super_super_super_super_super_super_super_super_super_super_s_long\` -\` - super_super_super_super_super_super_super_super_super_super_super_super_s_long -\`.to_s - -<<-HERE -This is a straight heredoc! -HERE - -<<-HERE -This is another straight heredoc, this time with interpolation! -#{interpolation} -So interpolated right now. -HERE - -abc = <<-HERE -This is a straight heredoc on an assign! -HERE - -<<-PARENT -This is a straight heredoc! -#{<<-CHILD -Why do I do this -CHILD -} -PARENT - -<<~HERE - This is a squiggly heredoc! -HERE - -<<~HERE - This is another squiggly heredoc, this time with interpolation! - #{interpolation} - So interpolated right now. -HERE - -abc = <<~HERE - This is a squiggly heredoc on an assign! -HERE - -<<~PARENT - This is a squiggly heredoc! - #{<<~CHILD - Why do I do this - CHILD -} -PARENT - -<<-GRAND -#{\\"interpolated\\"} -<<~PARENT - #{\\"more interpolated\\"} - <<-CHILD - #{\\"what is going on\\"} - CHILD - #{\\"more interpolated\\"} -PARENT -#{\\"interpolated\\"} -GRAND - -\\"abc \\\\\\"abc\\\\\\" abc\\" - -foo_bar 1, 2, 3, <<-HERE - baz -HERE - -foo.bar 1, 2, 3, <<-HERE - baz -HERE - -foo_bar(1, 2, 3, <<-HERE) - baz -HERE - -foo_bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo.bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo_bar(1, 2, 3, <<-HERE, <<-THERE) - here -HERE - there -THERE - -# rubocop:enable Layout/ClosingParenthesisIndentation -# rubocop:enable Layout/SpaceInsideStringInterpolation -# rubocop:enable Lint/InterpolationCheck -# rubocop:enable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:enable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:enable Style/StringLiteralsInInterpolation -# rubocop:enable Style/UnneededInterpolation - -# rubocop:enable Lint/UnneededCopDisableDirective -" -`; diff --git a/test/cases/__snapshots__/super.test.js.snap b/test/cases/__snapshots__/super.test.js.snap deleted file mode 100644 index 162763c0..00000000 --- a/test/cases/__snapshots__/super.test.js.snap +++ /dev/null @@ -1,18 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`super.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -super - -super() - -super 1 - -super(1) - -super 1, 2 - -super(1, 2) -" -`; diff --git a/test/cases/__snapshots__/while.test.js.snap b/test/cases/__snapshots__/while.test.js.snap deleted file mode 100644 index 932b85fa..00000000 --- a/test/cases/__snapshots__/while.test.js.snap +++ /dev/null @@ -1,63 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`while.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -1 while a - -1 while a - -1 while super_super_super_super_super_super_super_super_super_super_super_long - -while super_super_super_super_super_super_super_super_super_super_super_supelong - 1 -end - -1 until a - -1 until a - -1 until super_super_super_super_super_super_super_super_super_super_super_long - -until super_super_super_super_super_super_super_super_super_super_super_supelong - 1 -end -" -`; - -exports[`while.rb matches expected output 2`] = ` -"# frozen_string_literal: true - -while a - 1 -end - -while a - 1 -end - -while super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -while super_super_super_super_super_super_super_super_super_super_super_supelong - 1 -end - -until a - 1 -end - -until a - 1 -end - -until super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -until super_super_super_super_super_super_super_super_super_super_super_supelong - 1 -end -" -`; diff --git a/test/cases/__snapshots__/yield.test.js.snap b/test/cases/__snapshots__/yield.test.js.snap deleted file mode 100644 index 8b0cde96..00000000 --- a/test/cases/__snapshots__/yield.test.js.snap +++ /dev/null @@ -1,20 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`yield.rb matches expected output 1`] = ` -"# frozen_string_literal: true - -[1, 2, 3].each do |i| - yield - - yield i - - yield(i) - - yield i, 2 - - yield(i, 2) - - yield -end -" -`; diff --git a/test/cases/alias.rb b/test/cases/alias.rb deleted file mode 100644 index a0c15833..00000000 --- a/test/cases/alias.rb +++ /dev/null @@ -1,24 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Style/GlobalVars -class AliasTest < Minitest::Test - def test_plain_alias - assert_equal 'plain alias', foo - end - - def test_global_alias - $bar = 'global alias' - assert_equal 'global alias', $foo - end - - private - - def baz - 'plain alias' - end - - alias bar baz # inline comment - alias :foo :bar - alias $foo $bar -end -# rubocop:enable Style/GlobalVars diff --git a/test/cases/alias.test.js b/test/cases/alias.test.js deleted file mode 100644 index 721f4c62..00000000 --- a/test/cases/alias.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("alias.rb"); diff --git a/test/cases/array.rb b/test/cases/array.rb deleted file mode 100644 index 8e514369..00000000 --- a/test/cases/array.rb +++ /dev/null @@ -1,91 +0,0 @@ -# frozen_string_literal: true - -class ArrayTest < Minitest::Test - def test_basics - assert_equal_join '', [] - assert_equal_join '1, 2, 3', [1, 2, 3] - assert_equal_join 'a, b, c', ['a', 'b', 'c'] - assert_equal_join 'a, b c, d', ['a', 'b c', 'd'] - assert_equal_join 'a, b, c', [:a, :b, :c] - assert_equal_join 'a, b c, d', [:a, :'b c', :d] - end - - def test_literals - assert_equal_join 'a, b, c', %w[a b c] - assert_equal_join 'a, b, c', %i[a b c] - end - - # rubocop:disable Style/UnneededInterpolation - def test_string_arrays_with_interpolation - interp = 'b' - assert_equal_join 'a, b, c', ['a', "#{interp}", 'c'] - end - # rubocop:enable Style/UnneededInterpolation - - def test_literals_with_interpolation - foo = 'foo' - bar = 'bar' - baz = 'baz' - - assert_equal_join 'afooa, bbarb, cbazc', %W[a#{foo}a b#{bar}b c#{baz}c] - assert_equal_join 'afooa, bbarb, cbazc', %I[a#{foo}a b#{bar}b c#{baz}c] - end - - # rubocop:disable Lint/UnneededSplatExpansion - def test_splats - assert_equal_join "1, 2, 3, 4, 5, 6", [1, 2, *[3, 4], 5, 6] - end - # rubocop:enable Lint/UnneededSplatExpansion - - def test_long_elements - super_super_super_super_super_super_long = 'foo' - arr = [ - super_super_super_super_super_super_long, - super_super_super_super_super_super_long, [ - super_super_super_super_super_super_long - ] - ] - - assert_equal_join('foo, foo, foo', arr) - end - - def test_reference - arr = %w[foo bar] - - assert_equal 'bar', arr[1] - end - - def test_reference_assignment - arr = %w[foo bar] - arr[1] = 'baz' - - assert_equal 'baz', arr[1] - end - - def test_comments_within_reference_assignment - arr = %w[foo bar] - arr[1] = [ - # abc - %w[abc] - ] - - assert_equal_join 'abc', arr[1] - end - - def test_dynamic_reference - arr = [1, 2, 3] - idx = 0 - - assert_equal 1, arr[idx] - end - - private - - def assert_equal_join(expected, object) - assert_equal expected, object.join(', ') - end - - def assert_equal_str(expected, object) - assert_equal expected, object.to_s - end -end diff --git a/test/cases/array.test.js b/test/cases/array.test.js deleted file mode 100644 index 2dd8eddd..00000000 --- a/test/cases/array.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("array.rb"); -runCase("array.rb", { addTrailingCommas: true }, "trailing-commas.yml"); diff --git a/test/cases/assign.rb b/test/cases/assign.rb deleted file mode 100644 index b59d9a13..00000000 --- a/test/cases/assign.rb +++ /dev/null @@ -1,157 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/UselessAssignment, Style/ParallelAssignment -# rubocop:disable Metrics/MethodLength -# rubocop:disable Metrics/AbcSize -# rubocop:disable Metrics/LineLength -# rubocop:disable Metrics/ClassLength - -class AssignTest < Minitest::Test - def test_assignment - a = 1 - assert_equal 1, a - - a = - begin - 2 - end - assert_equal 2, a - end - - def test_parallel_assignment - a, b, c = [1, 2, 3] - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - a = 1, 2, 3 - assert_equal [1, 2, 3], a - - a, b, c = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - (a, b, c) = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - ((a, b, c)) = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - (((a, b, c))) = 1, 2, 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - end - - def test_assign_with_splat_operator - a, *b = 1, 2, 3 - assert_equal 1, a - assert_equal [2, 3], b - - a, *b, c, d = 1, 2, 3 - assert_equal 1, a - assert_equal [], b - assert_equal 2, c - assert_equal 3, d - - a, * = 1, 2, 3 - assert_equal 1, a - - a = *a - assert_equal [1], a - - (a, b), c = [1, 2], 3 - assert_equal 1, a - assert_equal 2, b - assert_equal 3, c - - * = [1, 2, 3] - - *, a = [1, 2, 3] - assert_equal 3, a - end - - def test_or_equals_operator - a = 2 - a ||= 1 - assert_equal 2, a - end - - def test_long_variable_assignment - super_super_super_super_super_long = 'bar' - super_super_super_long, super_super_super_long, super_super_super_long = - super_super_super_super_super_long, super_super_super_super_super_long, super_super_super_super_super_long - assert_equal super_super_super_long, 'bar' - - a = 2 - a ||= super_super_super_super_super_super_super_super_super_super_super_super_long - assert_equal 2, a - - super_super_super_super_super_super_super_super_super_super_super_long = 'foo' - a = [ - super_super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_super_long - ] - - assert_equal ['foo', 'foo', 'foo'], a - end - - def test_assign_hash - super_super_super_super_super_super_super_super_super_super_long = 'foo' - - hash = { - a: super_super_super_super_super_super_super_super_super_super_long, - b: super_super_super_super_super_super_super_super_super_super_long, - c: super_super_super_super_super_super_super_super_super_super_long - } - - assert_equal({ a: 'foo', b: 'foo', c: 'foo' }, hash) - end - - def test_assign_with_sort - # rubocop:disable Lint/UnneededCopDisableDirective - # rubocop:disable Layout/MultilineMethodCallIndentation - super_super_super_super_long = 'baz' - - arr = [super_super_super_super_long, super_super_super_super_long].sort - assert_equal ['baz', 'baz'], arr - - arr = { a: super_super_super_super_long, b: super_super_super_super_long }.sort.to_h - assert_equal({ a: 'baz', b: 'baz' }, arr) - - # rubocop:enable Layout/MultilineMethodCallIndentation - # rubocop:enable Lint/UnneededCopDisableDirective - end - - def test_setter_methods - a = Struct.new(:a).new - - a.a = 1 - assert_equal 1, a.a - - super_super_super_long = - Struct.new(:super_super_super_super_super_super_super_long).new - - super_super_super_super_super_super_super_super_super_super_super_long = 1 - - super_super_super_long.super_super_super_super_super_super_super_long = - super_super_super_super_super_super_super_super_super_super_super_long - - assert_equal( - super_super_super_long.super_super_super_super_super_super_super_long, - 1 - ) - end -end - -# rubocop:enable Lint/UselessAssignment, Style/ParallelAssignment -# rubocop:enable Metrics/MethodLength -# rubocop:enable Metrics/AbcSize -# rubocop:enable Metrics/LineLength -# rubocop:enable Metrics/ClassLength \ No newline at end of file diff --git a/test/cases/assign.test.js b/test/cases/assign.test.js deleted file mode 100644 index f5f12ed7..00000000 --- a/test/cases/assign.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("assign.rb"); diff --git a/test/cases/binary.rb b/test/cases/binary.rb deleted file mode 100644 index d42c87cc..00000000 --- a/test/cases/binary.rb +++ /dev/null @@ -1,19 +0,0 @@ -# frozen_string_literal: true - -class BinaryTest < Minitest::Test - def test_unbroken - value = true - - assert(value && value && value) - end - - def test_broken - super_super_super_super_super_long = true - - assert( - super_super_super_super_super_long && - super_super_super_super_super_long && - super_super_super_super_super_long - ) - end -end diff --git a/test/cases/binary.test.js b/test/cases/binary.test.js deleted file mode 100644 index 363cea84..00000000 --- a/test/cases/binary.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("binary.rb"); diff --git a/test/cases/blocks.rb b/test/cases/blocks.rb deleted file mode 100644 index eee9569f..00000000 --- a/test/cases/blocks.rb +++ /dev/null @@ -1,123 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/UnusedBlockArgument - -loop { 1 } - -loop do - 1 -end - -loop do - # foobar -end - -port ENV.fetch('PORT') { 3000 } - -test 'foobar' do -end - -te.st 'foobar' do -end - -test 'foobar' do - foobar -end - -te.st 'foobar' do - foobar -end - -test 'foobar' do |bar| - bar.to_s -end - -te.st 'foobar' do |bar| - bar.to_s -end - -loop { super_super_super_super_super_super_super_super_super_super_super_super_long } - -loop do - super_super_super_super_super_super_super_super_super_super_super_long -end - -loop { |i| 1 } - -loop { |i; j| 1 } - -loop do |i| - i -end - -loop { |*| i } - -loop { |(a, b)| i } - -loop { |a, (b, c), d, *e| i } - -loop { |i| super_super_super_super_super_super_super_super_super_super_super_super_long } - -loop do |i| - super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Metrics/LineLength -define_method :long_method_name_that_forces_overflow do |_some_long_argument_that_overflows = Time.now, _other_arg = nil| -end -# rubocop:enable Metrics/LineLength - -some_method.each do |foo| - bar - baz -end.to_i - -[ - super_super_super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_super_long -].to_s - -{ - a: 'super_super_super_super_super_super_super_super_super_super_long', - b: 'super_super_super_super_super_super_super_super_super_super_long' -}.to_s - -loop { |i| i.to_s } - -loop do |i| - i.to_s -end - -loop do |i| - i.to_s - i.next -end - -loop do |i| - i.to_s :db -end - -loop { |i, j| i.to_s } - -for i in [1, 2, 3] do - p i -end - -def change - change_table :foo do - column :bar - end -end - -foo 'foo' do |bar| - bar.to_s -end - -target.method object.map do |arg| - arg * 2 -end - -# from ruby test/ruby/test_call.rb -assert_nil(("a".sub! "b" do end&.foo {})) - -# rubocop:enable Lint/UnusedBlockArgument diff --git a/test/cases/blocks.test.js b/test/cases/blocks.test.js deleted file mode 100644 index 10b7486b..00000000 --- a/test/cases/blocks.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("blocks.rb"); diff --git a/test/cases/break.rb b/test/cases/break.rb deleted file mode 100644 index 1fde5f7f..00000000 --- a/test/cases/break.rb +++ /dev/null @@ -1,9 +0,0 @@ -# frozen_string_literal: true - -[].each { break } - -[].each { break 1 } - -[].each { break(1) } - -[].each { break 1, 2 } diff --git a/test/cases/break.test.js b/test/cases/break.test.js deleted file mode 100644 index cf4a78be..00000000 --- a/test/cases/break.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("break.rb"); diff --git a/test/cases/case.rb b/test/cases/case.rb deleted file mode 100644 index ccfae6e3..00000000 --- a/test/cases/case.rb +++ /dev/null @@ -1,40 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/EmptyWhen, Style/EmptyCaseCondition - -case -when a - 1 -end - -case a -when b - 1 -end - -case a -when b, c - 1 -end - -case a -when b -when c - 1 -end - -case a -when b - 1 -when c - 2 -end - -case a -when b - 1 -else - 2 -end - -# rubocop:enable Lint/EmptyWhen, Style/EmptyCaseCondition diff --git a/test/cases/case.test.js b/test/cases/case.test.js deleted file mode 100644 index 2d6ac625..00000000 --- a/test/cases/case.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("case.rb"); diff --git a/test/cases/class.rb b/test/cases/class.rb deleted file mode 100644 index 9da6eed5..00000000 --- a/test/cases/class.rb +++ /dev/null @@ -1,68 +0,0 @@ -# frozen_string_literal: true - -module Pret - module Tier - # object documentation - class Object; end - - # second object - # documentation - class Object - end - - # third object - # documentation - class Object - attr_accessor :foo - end - - class Object < BasicObject; end - - class Object < BasicObject - end - - class Object < BasicObject - # inside class documentation - attr_accessor :bar - end - - class SuperSuperSuperSuperSuperSuperSuperSuperSuperSuperSuperLongClassName; end - - module SuperSuperSuperSuperSuperSuperSuperSuperSuperSuperSuperLongModName; end - - class << self - # method documentation - def method1; end - - def method2; end - - def method3; end - - def method_with_a_long_name1; end - - def method_with_a_long_name2; end - - def method_with_a_long_name3; end - - undef method1 - undef method2, method3 - undef method_with_a_long_name1, method_with_a_long_name2, method_with_a_long_name3 - end - - module Prettier; end - - module Prettier - end - - module Prettier - # inside module documentation - attr_accessor :foo - end - end -end - -Pret::Tier::Object # rubocop:disable Lint/Void -Pret::TIER = 'config'.to_s - -::Pret::Tier::Object # rubocop:disable Lint/Void -::PRET = 'config'.to_s diff --git a/test/cases/class.test.js b/test/cases/class.test.js deleted file mode 100644 index 54dea449..00000000 --- a/test/cases/class.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("class.rb"); diff --git a/test/cases/comments.rb b/test/cases/comments.rb deleted file mode 100644 index b0863bb1..00000000 --- a/test/cases/comments.rb +++ /dev/null @@ -1,143 +0,0 @@ -# frozen_string_literal: true - -# this is a comment at -# the beginning of the file -# rubocop:disable Lint/Void - -loop do - # this is the only statement - # inside this loop -end - -loop do - # this is the first statement - # inside this loop - foo -end - -loop do - foo - # this is the last statement - # inside this loop -end - -def foo - # these are the only statements - # inside this method -end - -class Foo - # these are the only statements - # inside this class -end - -module Foo - # these are the only statements - # inside this module -end - -module Foo - class Foo - def foo - # this comment is inside a method - end - - def bar - print message # this is an inline comment - end - - def self.foo - # this comment is inside a self method - end - end -end - -foo # this is an inline comment -bar # this is another inline comment - -foo 'bar' # this is an inline comment - -[ - # these are comments - # inside of an array - foo, - # inside of an array - bar -] - -{ - # these are comments - foo: 'bar', - # inside of a hash - bar: 'baz' -} - -foo. # inline comment inside of a dot - bar - -Foo.where( - foo: bar, - bar: baz - # This is a comment -).to_a.find { |foo| foo.foo == bar.foo } - -if foo - # this is a comment in an if - bar -end - -unless foo - # this is a comment in an unless - bar -end - -while foo - # this is a comment at the beginning of a while - bar -end - -while foo - bar - # this is a comment at the end of a while -end - -until foo - # this is a comment at the beginning of a until - bar -end - -until foo - bar - # this is a comment at the end of a until -end - -case foo -when bar - # this is a comment at the beginning of a when - 1 -when baz - 2 - # this is a comment at the end of a when -end - -begin - # comment at the beginning of a begin - 1 -rescue - # comment at the beginning of a rescue - 2 -ensure - # comment at the end of a rescue - 3 -end - -# rubocop:enable Lint/Void -# this is a comment -# at the end of the file - -__END__ - /‾‾‾‾‾\ /‾‾‾‾‾\ /‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾/ /‾‾‾‾‾\ - / /‾‾/ / / /‾‾/ / / /‾‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ / /‾‾‾ / /‾‾/ / - / ‾‾‾ / / ‾‾‾_/ / _‾/ / / / / / / / _‾/ / ‾‾‾_/ - / /‾‾‾‾‾ / /‾\ \ / /__ / / / / __/ /_ / /__ / /‾\ \ -/_/ /_/ /_/ /____/ /_/ /_/ /_____/ /____/ /_/ /_/ diff --git a/test/cases/comments.test.js b/test/cases/comments.test.js deleted file mode 100644 index 912df6f1..00000000 --- a/test/cases/comments.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("comments.rb"); diff --git a/test/cases/conditionals.rb b/test/cases/conditionals.rb deleted file mode 100644 index 504006ab..00000000 --- a/test/cases/conditionals.rb +++ /dev/null @@ -1,112 +0,0 @@ -# frozen_string_literal: true - -if a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/Not, Style/NegatedIf, Lint/EmptyExpression -if not a - b -end - -# from ruby test/ruby/test_not.rb -assert_equal(true, (not ())) -# rubocop:enable Style/Not, Style/NegatedIf, Lint/EmptyExpression - -if a - break # comment -end - -if a - -else - b -end - -if a - 1 -elsif b - 2 -end - -if a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -if a - 1 -elsif b - 2 -elsif c - 3 -else - 4 -end - -unless a - super_super_super_super_super_super_super_super_super_super_super_super_long -end - -# rubocop:disable Style/UnlessElse -unless a - super_super_super_super_super_super_super_super_super_super_super_long -else - super_super_super_super_super_super_super_super_super_super_super_super_long -end -# rubocop:enable Style/UnlessElse - -1 if a - -1 if super_super_super_super_super_super_super_super_super_super_super_super_long - -1 unless a - -1 unless super_super_super_super_super_super_super_super_super_super_super_suplong - -if a - 1 -else - 2 -end - -unless a - 1 -else - 2 -end - -a ? 1 : 2 -a ? super_super_super_super_super_super_super_super_super_super_super_long - : super_super_super_super_super_super_super_super_super_super_super_super_long - -if a - b 1 -else - b(2) -end - -if a - b(1) -else - b 2 -end - -a b do - if a - a 'foo' - else - b - end -end - -if Some::Constant.super_super_super_super_super_super_super_super_super_super_long - 1 -elsif Some::Constant.super_super_super_super_super_super_super_super_super_super_long - 2 -end - -unless Some::Constant.super_super_super_super_super_super_super_super_super_super_long - 1 -end diff --git a/test/cases/conditionals.test.js b/test/cases/conditionals.test.js deleted file mode 100644 index 70a83b89..00000000 --- a/test/cases/conditionals.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("conditionals.rb"); -runCase("conditionals.rb", { inlineConditionals: false }, "block-conditionals.yml"); diff --git a/test/cases/defined.rb b/test/cases/defined.rb deleted file mode 100644 index 711c2643..00000000 --- a/test/cases/defined.rb +++ /dev/null @@ -1,19 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/Void - -defined? a # first - -defined?(a) # second - -defined? super_super_super_super_super_super_super_super_super_super_super_super_long - -defined?(super_super_super_super_super_super_super_super_super_super_super_super_long) - -defined?( - super_super_super_super_super_super_super_super_super_super_super_super_long -) - -defined?(a) # third - -# rubocop:enable Lint/Void diff --git a/test/cases/defined.test.js b/test/cases/defined.test.js deleted file mode 100644 index c5e648ff..00000000 --- a/test/cases/defined.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("defined.rb"); diff --git a/test/cases/embdoc.rb b/test/cases/embdoc.rb deleted file mode 100644 index 38cb8fba..00000000 --- a/test/cases/embdoc.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Style/BlockComments - -=begin -this is - -some really - -long documentation -that is contained -in an embdoc -=end - -class Foo -=begin -this is an embdoc inside a class -=end -end - -module Foo - class Foo -=begin -this is an embdoc even more indented -=end - end -end - -# rubocop:enable Style/BlockComments diff --git a/test/cases/embdoc.test.js b/test/cases/embdoc.test.js deleted file mode 100644 index 43bc6d31..00000000 --- a/test/cases/embdoc.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("embdoc.rb"); diff --git a/test/cases/encoding.rb b/test/cases/encoding.rb deleted file mode 100644 index 4f072356..00000000 --- a/test/cases/encoding.rb +++ /dev/null @@ -1,11 +0,0 @@ -# -*- encoding: binary -*- -# frozen_string_literal: true - -# rubocop:disable Lint/Void, Style/AsciiComments - -# il était -:il_était -"ひらがな" -/ひらがな/ - -# rubocop:enable Lint/Void, Style/AsciiComments diff --git a/test/cases/encoding.test.js b/test/cases/encoding.test.js deleted file mode 100644 index a721f07e..00000000 --- a/test/cases/encoding.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("encoding.rb"); diff --git a/test/cases/hash.rb b/test/cases/hash.rb deleted file mode 100644 index 9e55c04e..00000000 --- a/test/cases/hash.rb +++ /dev/null @@ -1,27 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/Void - -{} - -{ a: 'a', b: 'b', c: 'c' } - -{ :a => 'a', :b => 'b', :c => 'c' } - -{ Foo => 1, Bar => 2 } - -{ - super_super_super_super_super_super_super_super_long: - super_super_super_super_super_super_super_super_long, - super_super_super_super_super_super_super_super_super_long: { - super_super_super_super_super_super_super_super_long: - super_super_super_super_super_super_super_super_long - } -} - -foo :abc => true # some comment - -foobar alpha: alpha, beta: beta, gamma: gamma, delta: delta, epsilon: epsilon, zeta: zeta -foobar(alpha: alpha, beta: beta, gamma: gamma, delta: delta, epsilon: epsilon, zeta: zeta) - -# rubocop:enable Lint/Void diff --git a/test/cases/hash.test.js b/test/cases/hash.test.js deleted file mode 100644 index 502d75b6..00000000 --- a/test/cases/hash.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("hash.rb"); -runCase("hash.rb", { preferHashLabels: false }, "hash-rockets.yml"); diff --git a/test/cases/hooks.rb b/test/cases/hooks.rb deleted file mode 100644 index c2cb8b2d..00000000 --- a/test/cases/hooks.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Style/BeginBlock, Style/EndBlock - -BEGIN { - p 'begin' -} - -BEGIN { p 'begin' } - -BEGIN { super_super_super_super_super_super_super_super_super_super_super_super_long } - -BEGIN { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -END { - p 'end' -} - -END { p 'end' } - -END { super_super_super_super_super_super_super_super_super_super_super_super_long } - -END { - super_super_super_super_super_super_super_super_super_super_super_super_long -} - -# rubocop:enable Style/BeginBlock, Style/EndBlock diff --git a/test/cases/hooks.test.js b/test/cases/hooks.test.js deleted file mode 100644 index 591c7ad2..00000000 --- a/test/cases/hooks.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("hooks.rb"); diff --git a/test/cases/kwargs.rb b/test/cases/kwargs.rb deleted file mode 100644 index ddae5b00..00000000 --- a/test/cases/kwargs.rb +++ /dev/null @@ -1,16 +0,0 @@ -# frozen_string_literal: true - -class KwargsTest < Minitest::Test - def test_kwargs - assert_equal 10, add(alpha: 1, beta: 2, gamma: 3, delta: 4) - - args = { alpha: 1, beta: 2, gamma: 3 } - assert_equal 10, add(**args, delta: 4) - end - - private - - def add(alpha:, beta:, gamma: 1, delta: 2) - alpha + beta + gamma + delta - end -end diff --git a/test/cases/kwargs.test.js b/test/cases/kwargs.test.js deleted file mode 100644 index 2caa0a07..00000000 --- a/test/cases/kwargs.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("kwargs.rb"); diff --git a/test/cases/lambda.rb b/test/cases/lambda.rb deleted file mode 100644 index 43a4bea8..00000000 --- a/test/cases/lambda.rb +++ /dev/null @@ -1,31 +0,0 @@ -# frozen_string_literal: true - --> { 1 } - -->(a, b, c) { a + b + c } - --> { super_super_super_super_super_super_super_super_super_super_super_super_long } - -->(a, b, c) { a + b + c + super_super_super_super_super_super_super_super_super_long } - -a.(1, 2, 3) - -a.call(1, 2, 3) - -a[] - -a[1, 2, 3] - --> a { a } - --> () { 1 } - -command :foobar, ->(argument) { argument + argument } -comm.and :foobar, ->(argument) { argument + argument } - -command :fooooooooooooobaaaaaaarrrrr, ->(argument) { argument + argument + argument + argument + argument + argument } -comm.and :fooooooooooooobaaaaaaarrrrr, ->(argument) { argument + argument + argument + argument + argument + argument } - -# rubocop:disable Metrics/LineLength -command :fooooooooooooobaaaaaaarrrrr, ->(_fooooooooooooobaaaaaaarrrrr1, _fooooooooooooobaaaaaaarrrrr2, _fooooooooooooobaaaaaaarrrrr3) { true } -# rubocop:enable Metrics/LineLength diff --git a/test/cases/lambda.test.js b/test/cases/lambda.test.js deleted file mode 100644 index b2be3d07..00000000 --- a/test/cases/lambda.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("lambda.rb"); diff --git a/test/cases/layout.rb b/test/cases/layout.rb deleted file mode 100644 index 1c8e40ae..00000000 --- a/test/cases/layout.rb +++ /dev/null @@ -1,23 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/Void - -1 - -def foobar - 2 - - 3; 4; 5 - - - 6 -end - -7 -8 -9 - - -10 - -# rubocop:enable Lint/Void diff --git a/test/cases/layout.test.js b/test/cases/layout.test.js deleted file mode 100644 index fa3a6118..00000000 --- a/test/cases/layout.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("layout.rb"); diff --git a/test/cases/method.rb b/test/cases/method.rb deleted file mode 100644 index 3a4e739f..00000000 --- a/test/cases/method.rb +++ /dev/null @@ -1,72 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:disable Metrics/ParameterLists - -def foo; end - -def foo(); end - -def foo alpha -end - -def foo(alpha) -end - -def self.foo; end - -def self.foo(); end - -def self.foo alpha -end - -def self.foo(alpha) -end - -def foo(alpha, beta, *gamma, delta, epsilon:, zeta:, eta: 1, **theta, &block) - 'what' -end - -def foo(alpha:, beta:, gamma:, delta:, epsilon:, zeta:, eta:, theta:, iota:, kappa:, lambda:) - 'what' -end - -def foo(alpha); 1; end - -def foo(*); end - -def foo(**); end - -foo() - -foo(1) -foo(1, 2) -foo(1, 2, *abc) -foo(1, 2, *abc, 3, 4) -foo(aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii) -foo(aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii,) -foo(aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, &block) - -foo aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii -foo.foo aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii - -Foo::Bar::Baz.qux aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii -Foo::Bar::Baz.qux aaaaaaa, bbbbbbb, ccccccc, ddddddd, eeeeeee, fffffff, ggggggg, hhhhhhh, iiiiiii, &block - -foo(*bar) -foo(**baz) -foo(&block) - -foo(*bar, &block) -foo(**baz, &block) -foo(*bar, **baz, &block) - -foo(h: 1, **bar) -foo(**bar, h: 1) -foo(h: 1, **bar, i: 2) - -Foo::foo -foo&.foo - -# rubocop:enable Lint/DuplicateMethods, Lint/UnusedMethodArgument -# rubocop:enable Metrics/ParameterLists diff --git a/test/cases/method.test.js b/test/cases/method.test.js deleted file mode 100644 index 6eb9edbd..00000000 --- a/test/cases/method.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("method.rb"); -runCase("method.rb", { addTrailingCommas: true }, "trailing-commas.yml"); diff --git a/test/cases/next.rb b/test/cases/next.rb deleted file mode 100644 index 2d37f47c..00000000 --- a/test/cases/next.rb +++ /dev/null @@ -1,27 +0,0 @@ -# frozen_string_literal: true - -class NextTest < Minitest::Test - def test_no_args - result = [1, 2, 3].map { next } - - assert_equal [nil, nil, nil], result - end - - def test_one_arg_no_parens - result = [1, 2, 3].map { next 1 } - - assert_equal [1, 1, 1], result - end - - def test_one_arg_with_parens - result = [1, 2, 3].map { next(1) } - - assert_equal [1, 1, 1], result - end - - def test_multi_args_no_parens - result = [1, 2, 3].map { next 1, 2 } - - assert_equal [[1, 2], [1, 2], [1, 2]], result - end -end diff --git a/test/cases/next.test.js b/test/cases/next.test.js deleted file mode 100644 index 64fb2cbc..00000000 --- a/test/cases/next.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("next.rb"); diff --git a/test/cases/numbers.rb b/test/cases/numbers.rb deleted file mode 100644 index cec76803..00000000 --- a/test/cases/numbers.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -class NumbersTest < Minitest::Test - def test_numbers - assert_equal_str '123', 123 - assert_equal_str '-123', -123 - assert_equal_str '1123', 1_123 - assert_equal_str '-543', -543 - assert_equal_str '123456789123456789', 123_456_789_123_456_789 - end - - def test_floats - assert_equal_str '123.45', 123.45 - assert_equal_str '0.0012', 1.2e-3 - end - - def test_bases - assert_equal_str '43707', 0xaabb - assert_equal_str '255', 0o377 - assert_equal_str '-10', -0b1010 - assert_equal_str '9', 0b001_001 - end - - private - - def assert_equal_str(expected, value) - assert_equal expected, value.to_s - end -end diff --git a/test/cases/numbers.test.js b/test/cases/numbers.test.js deleted file mode 100644 index f446988c..00000000 --- a/test/cases/numbers.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("numbers.rb"); diff --git a/test/cases/ranges.rb b/test/cases/ranges.rb deleted file mode 100644 index 63cf92a8..00000000 --- a/test/cases/ranges.rb +++ /dev/null @@ -1,8 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/UselessAssignment - -dot2 = 1..2 # dot2 -dot3 = 3...4 # dot3 - -# rubocop:enable Lint/UselessAssignment diff --git a/test/cases/ranges.test.js b/test/cases/ranges.test.js deleted file mode 100644 index dd4721f3..00000000 --- a/test/cases/ranges.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("ranges.rb"); diff --git a/test/cases/regexp.rb b/test/cases/regexp.rb deleted file mode 100644 index 7ac01750..00000000 --- a/test/cases/regexp.rb +++ /dev/null @@ -1,76 +0,0 @@ -# frozen_string_literal: true - -class RegexpTest < Minitest::Test - def test_default - regexp = /abc/ - - assert_match regexp, 'abcde' - end - - def test_braces - regexp = %r{abc} - - assert_match regexp, 'abcde' - end - - def test_braces_with_slashes - regexp = %r{a/b/c} - - assert_match regexp, 'a/b/c/d/e' - end - - def test_slashes - regexp = %r/abc/ - - assert_match regexp, 'abcde' - end - - def test_brackets - regexp = %r[abc] - - assert_match regexp, 'abcde' - end - - def test_parens - regexp = %r(abc) - - assert_match regexp, 'abcde' - end - - def test_interpolation - inter = 'b' - regexp = /a#{inter}c/ - - assert_match regexp, 'abcde' - end - - def test_modifier - regexp = /abc/i - - assert_match regexp, 'ABCDE' - end - - def test_brace_modifier - regexp = %r{abc}i - - assert_match regexp, 'ABCDE' - end - - def test_global_interpolation - 'foo' =~ /foo/ - regexp = /#$&/ - - assert_match regexp, 'foobar' - end - - def test_float - float_pat = /\A - [[:digit:]]+ # 1 or more digits before the decimal point - (\. # Decimal point - [[:digit:]]+ # 1 or more digits after the decimal point - )? # The decimal point and following digits are optional - \Z/x - - assert_match float_pat, "12.56" - end -end diff --git a/test/cases/regexp.test.js b/test/cases/regexp.test.js deleted file mode 100644 index 9d4edc37..00000000 --- a/test/cases/regexp.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("regexp.rb"); diff --git a/test/cases/rescue.rb b/test/cases/rescue.rb deleted file mode 100644 index a81a4b39..00000000 --- a/test/cases/rescue.rb +++ /dev/null @@ -1,29 +0,0 @@ -# frozen_string_literal: true - -begin - 1 -rescue ArgumentError - retry -rescue NoMethodError => exception - puts exception - redo -rescue SyntaxError, NoMethodError - 2 -rescue SomeSuperSuperLongError, SomeOtherSuperSuperLongError, OneLastSuperLongError - 3 -rescue - 4 -else - 5 -ensure - 6 -end - -a rescue nil - -# from ruby spec/ruby/language/rescue_spec.rb -def foo - a -rescue A, *B => e - e -end diff --git a/test/cases/rescue.test.js b/test/cases/rescue.test.js deleted file mode 100644 index 75fa69a3..00000000 --- a/test/cases/rescue.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("rescue.rb"); diff --git a/test/cases/return.rb b/test/cases/return.rb deleted file mode 100644 index 4b4201b0..00000000 --- a/test/cases/return.rb +++ /dev/null @@ -1,27 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/UnneededCopDisableDirective -# rubocop:disable Style/GuardClause, Style/RedundantReturn - -def foo - return if a -end - -def bar - return 1 if a -end - -def baz - return(1) if a -end - -def qux - return 1, 2 if a -end - -def qax - return foo :bar if a -end - -# rubocop:enable Style/GuardClause, Style/RedundantReturn -# rubocop:enable Lint/UnneededCopDisableDirective diff --git a/test/cases/return.test.js b/test/cases/return.test.js deleted file mode 100644 index acf1de14..00000000 --- a/test/cases/return.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("return.rb"); diff --git a/test/cases/strings.rb b/test/cases/strings.rb deleted file mode 100644 index 08184918..00000000 --- a/test/cases/strings.rb +++ /dev/null @@ -1,167 +0,0 @@ -# frozen_string_literal: true - -# rubocop:disable Lint/UnneededCopDisableDirective - -# rubocop:disable Layout/ClosingParenthesisIndentation -# rubocop:disable Layout/SpaceInsideStringInterpolation -# rubocop:disable Lint/InterpolationCheck -# rubocop:disable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:disable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:disable Style/StringLiteralsInInterpolation -# rubocop:disable Style/UnneededInterpolation - -?a # these are CHARs -?\C-a -?\M-a -?\M-\C-a - -'' - -'abc' - -"abc's" - -"abc" - -"abc\n" - -'\n' -"\n" -'\x0' -"\x0" -'#{"\n"}' -"#{"\n"}" -"#{'\n'}" -"#{'\n'}#{"\n"}" -"#{"\n#{'\n'}#{"\n"}\n"}#{'\n'}" - -"\M-\C-a" - -"abc #{super} abc" - -"#{abc} abc" - -"{\"abc\": \"foo\nbar\"}" - -# rubocop:disable Style/Semicolon -"abc #{foo; bar} abc" -# rubocop:enable Style/Semicolon - -"abc #{de} fghi #{jkl} mno" - -'abc' \ - 'def' \ - 'ghi' - -"abc #{"abc #{abc} abc"} abc" - -{ 'a' => 1 } - -{ "a #{a}" => 1 } - -:"abc#{abc}abc" -:'abc#{abc}abc' - -%x[abc] -%x[super_super_super_super_super_super_super_super_super_super_super_super_s_long] -%x[super_super_super_super_super_super_super_super_super_super_super_super_s_long].to_s - -<<-HERE -This is a straight heredoc! -HERE - -<<-HERE -This is another straight heredoc, this time with interpolation! -#{interpolation} -So interpolated right now. -HERE - -abc = <<-HERE -This is a straight heredoc on an assign! -HERE - -<<-PARENT -This is a straight heredoc! -#{ -<<-CHILD -Why do I do this -CHILD -} -PARENT - -<<~HERE - This is a squiggly heredoc! -HERE - -<<~HERE - This is another squiggly heredoc, this time with interpolation! - #{interpolation} - So interpolated right now. -HERE - -abc = <<~HERE - This is a squiggly heredoc on an assign! -HERE - -<<~PARENT - This is a squiggly heredoc! - #{ - <<~CHILD - Why do I do this - CHILD - } -PARENT - -<<-GRAND -#{'interpolated'} -<<~PARENT - #{'more interpolated'} - <<-CHILD - #{'what is going on'} - CHILD - #{'more interpolated'} -PARENT -#{'interpolated'} -GRAND - -'abc "abc" abc' - -foo_bar 1, 2, 3, <<-HERE - baz -HERE - -foo.bar 1, 2, 3, <<-HERE - baz -HERE - -foo_bar(1, 2, 3, <<-HERE) - baz -HERE - -foo_bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo.bar 1, 2, 3, <<-HERE, <<-THERE - here -HERE - there -THERE - -foo_bar(1, 2, 3, <<-HERE, <<-THERE) - here -HERE - there -THERE - -# rubocop:enable Layout/ClosingParenthesisIndentation -# rubocop:enable Layout/SpaceInsideStringInterpolation -# rubocop:enable Lint/InterpolationCheck -# rubocop:enable Lint/LiteralInInterpolation, Layout/ClosingHeredocIndentation -# rubocop:enable Lint/Void, Layout/IndentHeredoc, Lint/UselessAssignment -# rubocop:enable Style/StringLiteralsInInterpolation -# rubocop:enable Style/UnneededInterpolation - -# rubocop:enable Lint/UnneededCopDisableDirective diff --git a/test/cases/strings.test.js b/test/cases/strings.test.js deleted file mode 100644 index 6288a53f..00000000 --- a/test/cases/strings.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("strings.rb"); -runCase("strings.rb", { preferSingleQuotes: false }, "double-quotes.yml"); diff --git a/test/cases/super.rb b/test/cases/super.rb deleted file mode 100644 index 7808b387..00000000 --- a/test/cases/super.rb +++ /dev/null @@ -1,13 +0,0 @@ -# frozen_string_literal: true - -super - -super() - -super 1 - -super(1) - -super 1, 2 - -super(1, 2) diff --git a/test/cases/super.test.js b/test/cases/super.test.js deleted file mode 100644 index d4bb70d3..00000000 --- a/test/cases/super.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("super.rb"); diff --git a/test/cases/while.rb b/test/cases/while.rb deleted file mode 100644 index 140c24cc..00000000 --- a/test/cases/while.rb +++ /dev/null @@ -1,25 +0,0 @@ -# frozen_string_literal: true - -while a - 1 -end - -1 while a - -while super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -1 while super_super_super_super_super_super_super_super_super_super_super_supelong - -until a - 1 -end - -1 until a - -until super_super_super_super_super_super_super_super_super_super_super_long - 1 -end - -1 until super_super_super_super_super_super_super_super_super_super_super_supelong diff --git a/test/cases/while.test.js b/test/cases/while.test.js deleted file mode 100644 index 909fd063..00000000 --- a/test/cases/while.test.js +++ /dev/null @@ -1,2 +0,0 @@ -runCase("while.rb"); -runCase("while.rb", { inlineLoops: false }, "block-loops.yml"); diff --git a/test/cases/yield.rb b/test/cases/yield.rb deleted file mode 100644 index d394e41f..00000000 --- a/test/cases/yield.rb +++ /dev/null @@ -1,15 +0,0 @@ -# frozen_string_literal: true - -[1, 2, 3].each do |i| - yield - - yield i - - yield(i) - - yield i, 2 - - yield(i, 2) - - yield -end diff --git a/test/cases/yield.test.js b/test/cases/yield.test.js deleted file mode 100644 index 79f676e6..00000000 --- a/test/cases/yield.test.js +++ /dev/null @@ -1 +0,0 @@ -runCase("yield.rb"); diff --git a/test/config/block-conditionals.yml b/test/config/block-conditionals.yml deleted file mode 100644 index ba0fc3b5..00000000 --- a/test/config/block-conditionals.yml +++ /dev/null @@ -1,4 +0,0 @@ -inherit_from: ./default.yml - -Style/IfUnlessModifier: - Enabled: false diff --git a/test/config/block-loops.yml b/test/config/block-loops.yml deleted file mode 100644 index 50ea6d07..00000000 --- a/test/config/block-loops.yml +++ /dev/null @@ -1,4 +0,0 @@ -inherit_from: ./default.yml - -Style/WhileUntilModifier: - Enabled: false diff --git a/test/config/default.yml b/test/config/default.yml deleted file mode 100644 index a6aaf1fe..00000000 --- a/test/config/default.yml +++ /dev/null @@ -1,5 +0,0 @@ -AllCops: - TargetRubyVersion: 2.5 - -Style/Documentation: - Enabled: false diff --git a/test/config/double-quotes.yml b/test/config/double-quotes.yml deleted file mode 100644 index 9b122d37..00000000 --- a/test/config/double-quotes.yml +++ /dev/null @@ -1,4 +0,0 @@ -inherit_from: ./default.yml - -Style/StringLiterals: - EnforcedStyle: double_quotes diff --git a/test/config/hash-rockets.yml b/test/config/hash-rockets.yml deleted file mode 100644 index 41364e3b..00000000 --- a/test/config/hash-rockets.yml +++ /dev/null @@ -1,4 +0,0 @@ -inherit_from: ./default.yml - -Style/HashSyntax: - EnforcedStyle: hash_rockets diff --git a/test/config/trailing-commas.yml b/test/config/trailing-commas.yml deleted file mode 100644 index 77143693..00000000 --- a/test/config/trailing-commas.yml +++ /dev/null @@ -1,10 +0,0 @@ -inherit_from: ./default.yml - -Style/TrailingCommaInArguments: - EnforcedStyleForMultiline: consistent_comma - -Style/TrailingCommaInArrayLiteral: - EnforcedStyleForMultiline: consistent_comma - -Style/TrailingCommaInHashLiteral: - EnforcedStyleForMultiline: consistent_comma diff --git a/test/errors.test.js b/test/errors.test.js deleted file mode 100644 index 7dc22ccd..00000000 --- a/test/errors.test.js +++ /dev/null @@ -1,21 +0,0 @@ -const prettier = require("prettier"); - -const format = content => () => prettier.format(content, { - parser: "ruby", plugins: ["."] -}); - -test("alias errors throws on parsing", () => { - expect(format("alias $a $1")).toThrow("Invalid ruby"); -}); - -test("assignment errors", () => { - expect(format("self = 1")).toThrow("Invalid ruby"); -}); - -test("class creation errors", () => { - expect(format("class foo; end")).toThrow("Invalid ruby"); -}); - -test("argument type errors", () => { - expect(format("def foo($a); end")).toThrow("Invalid ruby"); -}); diff --git a/test/escapePattern.test.js b/test/escapePattern.test.js deleted file mode 100644 index 882b0950..00000000 --- a/test/escapePattern.test.js +++ /dev/null @@ -1,62 +0,0 @@ -const escapePattern = require("../src/escapePattern"); - -describe("escape sequences", () => { - const should = value => string => ( - expect(escapePattern.test(string)).toBe(value) - ); - - const shouldMatch = should(true); - const shouldNotMatch = should(false); - - test("identifies simple escapes", () => { - shouldMatch("\\t"); - shouldMatch("\\n"); - shouldNotMatch("\\x"); - }); - - test("identifies octal bits", () => { - shouldMatch("\\1"); - shouldMatch("\\12"); - shouldNotMatch("\\8"); - }); - - test("identifies hex bits", () => { - shouldMatch("\\x0"); - shouldMatch("\\xa"); - shouldMatch("\\xab"); - shouldNotMatch("\\xg"); - }); - - test("identifies unicode char", () => { - shouldMatch("\\uabcd"); - shouldNotMatch("\\uabcg"); - }); - - test("identifies unicode chars", () => { - shouldMatch("\\u{abcd abce abcf}"); - shouldNotMatch("\\u{abcd abce abcg}"); - }); - - test("identifies controls", () => { - shouldMatch("\\ca"); - shouldMatch("\\C-a"); - shouldNotMatch("\\c🎉"); - }); - - test("identifies metas", () => { - shouldMatch("\\M-a"); - shouldNotMatch("\\M-🎉"); - }); - - test("identifies meta controls", () => { - shouldMatch("\\M-\\C-a"); - shouldMatch("\\M-\\ca"); - shouldMatch("\\c\\M-a"); - }); - - test("identifies deletes", () => { - shouldMatch("\\c?"); - shouldMatch("\\C-?"); - shouldNotMatch("\\d?"); - }); -}); diff --git a/test/hasPragma.test.js b/test/hasPragma.test.js deleted file mode 100644 index c9acc47e..00000000 --- a/test/hasPragma.test.js +++ /dev/null @@ -1,17 +0,0 @@ -#!/usr/bin/env node - -const { hasPragma } = require("../src/ruby").parsers.ruby; - -describe("hasPragma", () => { - test("checks for @prettier comments", () => { - expect(hasPragma("# @prettier")).toBe(true); - }); - - test("checks for @format comments", () => { - expect(hasPragma("# @format")).toBe(true); - }); - - test("does not check for anything else", () => { - expect(hasPragma("# @foobar")).toBe(false); - }); -}); diff --git a/test/js/files.test.js b/test/js/files.test.js new file mode 100644 index 00000000..05b239bd --- /dev/null +++ b/test/js/files.test.js @@ -0,0 +1,15 @@ +import { getFileInfo } from "prettier"; +import url from "url"; +import plugin from "../../src/plugin.js"; + +describe("files", () => { + const cases = ["files/Gemfile", "files/shebang", "files/test.rake"]; + + test.each(cases)("infers Ruby parser from %s", async (filename) => { + const filepath = url.fileURLToPath(new URL(filename, import.meta.url)); + const fileInfoOptions = { plugins: [plugin] }; + + const { inferredParser } = await getFileInfo(filepath, fileInfoOptions); + expect(inferredParser).toEqual("ruby"); + }); +}); diff --git a/test/js/files/Gemfile b/test/js/files/Gemfile new file mode 100644 index 00000000..e69de29b diff --git a/test/js/files/shebang b/test/js/files/shebang new file mode 100755 index 00000000..49ffd26f --- /dev/null +++ b/test/js/files/shebang @@ -0,0 +1 @@ +#!/usr/bin/env ruby diff --git a/test/js/files/test.rake b/test/js/files/test.rake new file mode 100644 index 00000000..e69de29b diff --git a/test/js/globalSetup.js b/test/js/globalSetup.js new file mode 100644 index 00000000..72c9be34 --- /dev/null +++ b/test/js/globalSetup.js @@ -0,0 +1,30 @@ +import { spawnSync } from "child_process"; +import { spawnServer } from "../../src/plugin.js"; + +// This is somewhat similar to the spawnServer function in parseSync but +// slightly different in that it logs its information into environment variables +// so that it can be reused across the test suite. +async function globalSetup() { + // Set a RUBY_VERSION environment variable because certain tests will only run + // for certain versions of Ruby. + const args = ["--disable-gems", "-e", "puts RUBY_VERSION"]; + process.env.RUBY_VERSION = spawnSync("ruby", args) + .stdout.toString("utf-8") + .trim(); + + const { serverPID, connectionFilepath, connectionOptions } = + await spawnServer( + { + rubyPlugins: "", + rubySingleQuote: false, + trailingComma: "none" + }, + false + ); + + process.env.PRETTIER_RUBY_PID = serverPID; + process.env.PRETTIER_RUBY_FILE = connectionFilepath; + process.env.PRETTIER_RUBY_HOST = JSON.stringify(connectionOptions); +} + +export default globalSetup; diff --git a/test/js/globalTeardown.js b/test/js/globalTeardown.js new file mode 100644 index 00000000..c51948b9 --- /dev/null +++ b/test/js/globalTeardown.js @@ -0,0 +1,25 @@ +import fs from "fs"; + +// If a parse server was successfully spawned, then its process ID will be in +// the PRETTIER_RUBY_PID environment variable. At the end of the test suite we +// should send a kill signal to it. +function globalTeardown() { + const serverPID = process.env.PRETTIER_RUBY_PID; + const connectionFilepath = process.env.PRETTIER_RUBY_FILE; + + if (serverPID) { + try { + const pid = process.platform === "win32" ? serverPID : -serverPID; + process.kill(pid, "SIGINT"); + } catch (error) { + console.error("Failed to kill the parser process in globalTeardown."); + throw error; + } + } + + if (fs.existsSync(connectionFilepath)) { + fs.unlinkSync(connectionFilepath); + } +} + +export default globalTeardown; diff --git a/test/js/haml/comment.test.js b/test/js/haml/comment.test.js new file mode 100644 index 00000000..6ceac558 --- /dev/null +++ b/test/js/haml/comment.test.js @@ -0,0 +1,36 @@ +import { haml } from "../utils"; + +describe("comment", () => { + test("single line", () => { + return expect( + haml("/ This is the peanutbutterjelly element") + ).toMatchFormat(); + }); + + test("multi line", () => { + const content = haml(` + / + %p This doesn't render, because it's commented out! + `); + + return expect(content).toMatchFormat(); + }); + + test("conditional", () => { + const content = haml(` + /[if IE] + %h1 Get Firefox + `); + + return expect(content).toMatchFormat(); + }); + + test("revealed", () => { + const content = haml(` + /![if !IE] + You are not using Internet Explorer, or are using version 10+. + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/haml/doctype.test.js b/test/js/haml/doctype.test.js new file mode 100644 index 00000000..5e6f1ba1 --- /dev/null +++ b/test/js/haml/doctype.test.js @@ -0,0 +1,43 @@ +import { haml } from "../utils"; + +describe("doctype", () => { + test("basic", () => { + return expect(haml("!!! Basic")).toMatchFormat(); + }); + + test("frameset", () => { + return expect(haml("!!! Frameset")).toMatchFormat(); + }); + + test("mobile", () => { + return expect(haml("!!! Mobile")).toMatchFormat(); + }); + + test("rdfa", () => { + return expect(haml("!!! RDFa")).toMatchFormat(); + }); + + test("strict", () => { + return expect(haml("!!! Strict")).toMatchFormat(); + }); + + test("xml", () => { + return expect(haml("!!! XML")).toMatchFormat(); + }); + + test("encoding", () => { + return expect(haml("!!! XML iso-8859-1")).toMatchFormat(); + }); + + test("1.1", () => { + return expect(haml("!!! 1.1")).toMatchFormat(); + }); + + test("5", () => { + return expect(haml("!!! 5")).toMatchFormat(); + }); + + test("misc", () => { + return expect(haml("!!! foo")).toMatchFormat(); + }); +}); diff --git a/test/js/haml/filter.test.js b/test/js/haml/filter.test.js new file mode 100644 index 00000000..14e7e223 --- /dev/null +++ b/test/js/haml/filter.test.js @@ -0,0 +1,31 @@ +import { haml } from "../utils"; + +describe("filter", () => { + test("self", () => { + const content = haml(` + :haml + -# comment + `); + + return expect(content).toMatchFormat(); + }); + + test("custom", () => { + const content = haml(` + :python + def foo: + bar + `); + + return expect(content).toMatchFormat(); + }); + + test("css", () => { + const content = haml(` + :css + .foo { height: 100px; width: 100px; } + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/haml/hamlComment.test.js b/test/js/haml/hamlComment.test.js new file mode 100644 index 00000000..757f241b --- /dev/null +++ b/test/js/haml/hamlComment.test.js @@ -0,0 +1,26 @@ +import { haml } from "../utils"; + +describe("haml comment", () => { + test("empty", () => { + return expect(haml("-#")).toMatchFormat(); + }); + + test("same line", () => { + return expect(haml("-# comment")).toMatchFormat(); + }); + + test("multi line", () => { + const content = haml(` + -# + this is + a multi line + comment + `); + + return expect(content).toMatchFormat(); + }); + + test("weird spacing same line", () => { + return expect(haml("-# foobar ")).toChangeFormat("-# foobar"); + }); +}); diff --git a/test/js/haml/plain.test.js b/test/js/haml/plain.test.js new file mode 100644 index 00000000..87b1e79f --- /dev/null +++ b/test/js/haml/plain.test.js @@ -0,0 +1,13 @@ +import { haml } from "../utils"; + +describe("plain", () => { + const specialChars = ["%", ".", "#", "/", "!", "=", "&", "~", "-", "\\", ":"]; + + test.each(specialChars)("escapes starting %s", (specialChar) => { + return expect(haml(`\\${specialChar}`)).toMatchFormat(); + }); + + test("does not unnecessarily escape other characters", () => { + return expect(haml("foo")).toMatchFormat(); + }); +}); diff --git a/test/js/haml/script.test.js b/test/js/haml/script.test.js new file mode 100644 index 00000000..f9c56e02 --- /dev/null +++ b/test/js/haml/script.test.js @@ -0,0 +1,34 @@ +import { haml } from "../utils"; + +describe("script", () => { + test("single line", () => { + return expect(haml('%p= "hello"')).toMatchFormat(); + }); + + test("multi line", () => { + const content = haml(` + %p + = ['hi', 'there', 'reader!'].join " " + = "yo" + `); + + return expect(content).toMatchFormat(); + }); + + test("escape with interpolate", () => { + return expect(haml(`&= "I like cheese & crackers"`)).toMatchFormat(); + }); + + test("children", () => { + const content = haml(` + = foo + = bar + `); + + return expect(content).toMatchFormat(); + }); + + test("preserve", () => { + return expect(haml('~ "Foo\\n
Bar\\nBaz
"')).toMatchFormat(); + }); +}); diff --git a/test/js/haml/silentScript.test.js b/test/js/haml/silentScript.test.js new file mode 100644 index 00000000..c7e78177 --- /dev/null +++ b/test/js/haml/silentScript.test.js @@ -0,0 +1,72 @@ +import { haml } from "../utils"; + +describe("silent script", () => { + test("single line", () => { + return expect(haml('- foo = "hello"')).toMatchFormat(); + }); + + test("multi-line", () => { + const content = haml(` + - foo + - bar + `); + + return expect(content).toMatchFormat(); + }); + + test("multi line with case", () => { + const content = haml(` + - case foo + - when 1 + = "1" + %span bar + - when 2 + = "2" + - else + = "3" + `); + + return expect(content).toMatchFormat(); + }); + + test("multi line with if/else", () => { + const content = haml(` + - if foo + %span bar + -# baz + - elsif qux + = "qax" + - else + -# qix + `); + + return expect(content).toMatchFormat(); + }); + + test("multi line with unless/else", () => { + const content = haml(` + - unless foo + %span bar + -# baz + - elsif qux + = "qax" + - else + -# qix + `); + + return expect(content).toMatchFormat(); + }); + + test("multi line with embedded", () => { + const content = haml(` + - if foo + %span foo + - if bar + %span bar + - elsif baz + %span baz + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/haml/tag.test.js b/test/js/haml/tag.test.js new file mode 100644 index 00000000..70f4c17f --- /dev/null +++ b/test/js/haml/tag.test.js @@ -0,0 +1,136 @@ +import { long, haml } from "../utils"; + +describe("tag", () => { + test("class", () => { + return expect(haml("%p.foo")).toMatchFormat(); + }); + + test("class multiple", () => { + return expect(haml("%p.foo.bar.baz")).toMatchFormat(); + }); + + test("id", () => { + return expect(haml("%p#foo")).toMatchFormat(); + }); + + test("classes and id", () => { + return expect(haml("%p.foo.bar#baz")).toMatchFormat(); + }); + + test("self closing", () => { + return expect(haml("%br/")).toMatchFormat(); + }); + + test("whitespace removal left single line", () => { + return expect(haml('%p>= "Foo\\nBar"')).toMatchFormat(); + }); + + test("whitespace removal right single line", () => { + return expect(haml('%p<= "Foo\\nBar"')).toMatchFormat(); + }); + + test("whitespace removal right multi line", () => { + const content = haml(` + %blockquote< + %div + Foo! + `); + + return expect(content).toMatchFormat(); + }); + + test("dynamic attribute", () => { + return expect(haml("%span{html_attrs('fr-fr')}")).toMatchFormat(); + }); + + test("dynamic attributes (ruby hash)", () => { + const content = haml(`%div{data: { controller: "lesson-evaluation" }}`); + + return expect(content).toMatchFormat(); + }); + + test("dynamic attributes (html-style)", () => { + const content = haml("%img(title=@title alt=@alt)/"); + + return expect(content).toMatchFormat(); + }); + + describe("static attributes", () => { + test("basic", () => { + return expect(haml("%span(foo)")).toChangeFormat("%span{foo: true}"); + }); + + test("hash label, single quote", () => { + const content = haml(`%section(xml:lang="en" title="title")`); + const expected = `%section{"xml:lang": "en", title: "title"}`; + + return expect(content).toChangeFormat(expected); + }); + + test("hash label, double quote", () => { + const content = haml(`%section(xml:lang="en" title="title")`); + const expected = `%section{"xml:lang": "en", title: "title"}`; + + return expect(content).toChangeFormat(expected); + }); + + test("hash label, single quote, interpolation", () => { + const content = haml(`%section{title: "#{title}"}`); + + return expect(content).toMatchFormat(); + }); + + test("non-strings", () => { + const content = haml(`%section(foo=1 bar=2)`); + const expected = `%section(foo=1 bar=2)`; + + return expect(content).toChangeFormat(expected); + }); + + test("attributes prefixed with @", () => { + return Promise.all([ + expect(haml(`%span{"@click": "open = true"}`)).toMatchFormat(), + expect(haml(`%span{"@click.outside": "open = true"}`)).toMatchFormat(), + expect( + haml(`%span{"@keydown.arrow-up.prevent": "open = true"}`) + ).toMatchFormat() + ]); + }); + }); + + test("object reference", () => { + const content = haml(` + %div[@user, :greeting] + %bar[290]/ + Hello! + `); + + return expect(content).toMatchFormat(); + }); + + test("long declaration before text", () => { + const content = haml(`%button{ data: { current: ${long} } } foo`); + const expected = haml(` + %button{ + data: { + current: ${long} + } + } + foo + `); + + return expect(content).toChangeFormat(expected); + }); + + test("with quotes in string", () => { + const content = haml(`%div{title: "escaping quotes, it's annoying"}`); + + return expect(content).toMatchFormat(); + }); + + test("with interpolation in the value", () => { + const content = haml(`%p hello"#{1 + 2} little pigs"`); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/rbs/combination.txt b/test/js/rbs/combination.txt new file mode 100644 index 00000000..2761e7a7 --- /dev/null +++ b/test/js/rbs/combination.txt @@ -0,0 +1,5 @@ +untyped | void | nil +untyped & void & nil +untyped | void & nil +untyped & void | nil +untyped & (void | nil) diff --git a/test/js/rbs/constant.txt b/test/js/rbs/constant.txt new file mode 100644 index 00000000..763be8d4 --- /dev/null +++ b/test/js/rbs/constant.txt @@ -0,0 +1,11 @@ +Object +::Object +Enumerator::Lazy +::Enumerator::Lazy +Array[untyped] +foo +::foo +Foo::foo +::Foo::foo +singleton(Object) +singleton(::Object) diff --git a/test/js/rbs/declaration.txt b/test/js/rbs/declaration.txt new file mode 100644 index 00000000..2cabe37b --- /dev/null +++ b/test/js/rbs/declaration.txt @@ -0,0 +1,3 @@ +Hello::World: Integer +$name: String +type ::Module::foo = String | Integer diff --git a/test/js/rbs/generic.txt b/test/js/rbs/generic.txt new file mode 100644 index 00000000..6ea1e1ac --- /dev/null +++ b/test/js/rbs/generic.txt @@ -0,0 +1,7 @@ +[A, B] (A) -> B +[A] (A) -> A +[A, B, C] -> ::Foo[A, B, C] +[A, B] -> [A, B] +[A] -> { foo: A } +[A, B] (A & B) -> void +[A, B, C, D] -> ::Foo[A, B, C, D] diff --git a/test/js/rbs/interface.txt b/test/js/rbs/interface.txt new file mode 100644 index 00000000..ebfb7c53 --- /dev/null +++ b/test/js/rbs/interface.txt @@ -0,0 +1,5 @@ +_Foo +::_Foo +Foo::_Foo +::Foo::_Foo +_Foo[untyped, nil] diff --git a/test/js/rbs/literal.txt b/test/js/rbs/literal.txt new file mode 100644 index 00000000..4fff20f4 --- /dev/null +++ b/test/js/rbs/literal.txt @@ -0,0 +1,9 @@ +1 +-1 +:foo +:foo? +:$foo +:@foo +:@@foo +:+ +:- diff --git a/test/js/rbs/member.txt b/test/js/rbs/member.txt new file mode 100644 index 00000000..b6233f3a --- /dev/null +++ b/test/js/rbs/member.txt @@ -0,0 +1,28 @@ +alias foo bar +alias self.foo self.bar +attr_accessor foo: Foo +attr_accessor self.foo: Foo +attr_accessor foo(): Foo +attr_accessor self.foo(): Foo +attr_accessor foo(@bar): Foo +attr_accessor self.foo(@bar): Foo +attr_reader foo: Foo +attr_reader self.foo: Foo +attr_reader foo(): Foo +attr_reader self.foo(): Foo +attr_reader foo(@bar): Foo +attr_reader self.foo(@bar): Foo +attr_writer foo: Foo +attr_writer self.foo: Foo +attr_writer foo(): Foo +attr_writer self.foo(): Foo +attr_writer foo(@bar): Foo +attr_writer self.foo(@bar): Foo +@foo: Foo +self.@foo: Foo +@@foo: Foo +include Foo +prepend Foo +extend Foo +private +public diff --git a/test/js/rbs/method.txt b/test/js/rbs/method.txt new file mode 100644 index 00000000..dfd4dd65 --- /dev/null +++ b/test/js/rbs/method.txt @@ -0,0 +1,17 @@ +def t: -> void +def t: -> void | ... +def t: -> ("a" | "b" | "c") +def t: -> ("a" | "b" | "c")? +def t: -> ("a" & "b" & "c") +def t: -> ("a" & "b" & "c")? +def t: -> ("a" & ("b" | "c")) +def t: -> ("a" & ("b" | "c"))? +def self.t: -> void +def self.t: -> void | ... +def self?.t: -> void +def self?.t: -> void | ... +def t: { -> void } -> void +def t: ?{ -> void } -> void +def `self`: -> void +def `: -> void +def t: (untyped `untyped`) -> void diff --git a/test/js/rbs/optional.txt b/test/js/rbs/optional.txt new file mode 100644 index 00000000..e7842ee6 --- /dev/null +++ b/test/js/rbs/optional.txt @@ -0,0 +1,5 @@ +untyped? +^-> untyped? +untyped | void? +:foo?? +:foo!? diff --git a/test/js/rbs/plain.txt b/test/js/rbs/plain.txt new file mode 100644 index 00000000..99ab75f5 --- /dev/null +++ b/test/js/rbs/plain.txt @@ -0,0 +1,11 @@ +void +untyped +bool +true +false +nil +top +bot +self +instance +class diff --git a/test/js/rbs/proc.txt b/test/js/rbs/proc.txt new file mode 100644 index 00000000..4d77333b --- /dev/null +++ b/test/js/rbs/proc.txt @@ -0,0 +1,11 @@ +^-> void +^(untyped) -> void +^(untyped, void) -> void +^(untyped x, void _y) -> void +^(untyped x, ?void, ?nil y) -> void +^(untyped x, ?void, ?nil y, *untyped a) -> void +^(untyped x, *untyped a, nil z) -> void +^(foo: untyped, _bar: nil bar) -> void +^(?_bar: nil, **untyped rest) -> void +^-> void +^{ -> void } -> void diff --git a/test/js/rbs/rbs.test.js b/test/js/rbs/rbs.test.js new file mode 100644 index 00000000..3e6addac --- /dev/null +++ b/test/js/rbs/rbs.test.js @@ -0,0 +1,319 @@ +import { readFileSync } from "fs"; +import { platform } from "os"; +import { atLeastVersion, rbs } from "../utils"; + +function testCases(name, transform) { + const buffer = readFileSync(new URL(`${name}.txt`, import.meta.url)); + const sources = buffer.toString().slice(0, -1).split(/\r?\n/); + + sources.forEach((source) => { + test(source, () => { + return expect(rbs(transform(source))).toMatchFormat(); + }); + }); +} + +function describeCases(name, transform) { + describe(name, () => { + testCases(name, transform); + }); +} + +describe("rbs", () => { + describeCases("combination", (source) => `T: ${source}`); + + describeCases("constant", (source) => `T: ${source}`); + + describe("declaration", () => { + testCases("declaration", (source) => source); + + test("interface", () => { + const content = rbs(` + interface _Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("interface with type params", () => { + const content = rbs(` + interface _Foo[A, B] + end + `); + + return expect(content).toMatchFormat(); + }); + + if (atLeastVersion("3.1")) { + test("interface with bounded type param", () => { + const content = rbs(` + interface _Foo[A < B] + end + `); + + return expect(content).toMatchFormat(); + }); + + test("interface with fancy bounded type params", () => { + const content = rbs(` + interface _Foo[U < singleton(::Hash), V < W[X, Y]] + end + `); + + return expect(content).toMatchFormat(); + }); + } + + test("class", () => { + const content = rbs(` + class Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with type params", () => { + const content = rbs(` + class Foo[A, B] + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with complicated type params", () => { + const content = rbs(` + class Foo[unchecked in A, unchecked out B, in C, out D, unchecked E, unchecked F, G, H] + end + `); + + return expect(content).toMatchFormat(); + }); + + if (atLeastVersion("3.1")) { + test("class with bounded type param", () => { + const content = rbs(` + class Foo[A < B] + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with fancy bounded type params", () => { + const content = rbs(` + class Foo[U < singleton(::Hash), V < W[X, Y]] + end + `); + + return expect(content).toMatchFormat(); + }); + } + + test("class with annotations", () => { + const content = rbs(` + %a{This is an annotation.} + class Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with annotations that cannot be switched to braces", () => { + const content = rbs(` + %a + class Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with comments", () => { + const content = rbs(` + # This is a comment. + class Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("class with superclass", () => { + const content = rbs(` + class Foo < Bar + end + `); + + return expect(content).toMatchFormat(); + }); + + test("module", () => { + const content = rbs(` + module Foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("module with type params", () => { + const content = rbs(` + module Foo[A, B] + end + `); + + return expect(content).toMatchFormat(); + }); + + test("module with self types", () => { + const content = rbs(` + module Foo : A + end + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple empty lines", () => { + const content = rbs(` + class Foo + A: 1 + B: 2 + + + C: 3 + end + `); + + const expected = rbs(` + class Foo + A: 1 + B: 2 + + C: 3 + end + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + describeCases( + "generic", + (source) => ` + class T + def t: ${source} + end + ` + ); + + describeCases("interface", (source) => `T: ${source}`); + + describe("literal", () => { + testCases("literal", (source) => `T: ${source}`); + + test("+1 drops the plus sign", () => { + return expect(rbs("T: +1")).toChangeFormat("T: 1"); + }); + + test("uses default quotes", () => { + return expect(rbs(`T: "foo"`)).toMatchFormat(); + }); + + test("changes quotes to match", () => { + return expect(rbs("T: 'foo'")).toChangeFormat(`T: "foo"`); + }); + + test("keeps string the same when there is an escape sequence", () => { + return expect(rbs(`T: "super \\a duper"`)).toMatchFormat(); + }); + + test("unescapes double quotes when using single quotes", () => { + return expect(rbs(`T: "super \\" duper"`)).toChangeFormat( + `T: "super \\" duper"` + ); + }); + + test("unescapes single quotes when using double quotes", () => { + return expect(rbs(`T: 'super \\' duper'`)).toChangeFormat( + `T: 'super \\' duper'` + ); + }); + + test("maintains escape sequences when using double quotes", () => { + return expect( + rbs(`T: "escape sequences \\a\\b\\e\\f\\n\\r"`) + ).toMatchFormat(); + }); + + test("maintains not escape sequences when using single quotes", () => { + return expect( + rbs(`T: 'escape sequences \\a\\b\\e\\f\\n\\r'`) + ).toMatchFormat(); + }); + }); + + describeCases( + "member", + (source) => ` + class T + ${source} + end + ` + ); + + describeCases( + "method", + (source) => ` + class T + ${source} + end + ` + ); + + describe("optional", () => { + testCases("optional", (source) => `T: ${source}`); + + test("removes optional space before question mark", () => { + return expect(rbs("T: :foo ?")).toChangeFormat("T: :foo?"); + }); + }); + + describeCases("plain", (source) => `T: ${source}`); + + describe("proc", () => { + testCases("proc", (source) => `T: ${source}`); + + test("drops optional parentheses when there are no params", () => { + return expect(rbs("T: ^() -> void")).toChangeFormat("T: ^-> void"); + }); + + test("drops optional parentheses with block param when there are no params to the block", () => { + return expect(rbs("T: ^{ () -> void } -> void")).toChangeFormat( + "T: ^{ -> void } -> void" + ); + }); + }); + + describeCases("record", (source) => `T: ${source}`); + + // For some reason these tests are failing on windows on Ruby < 3.0. I'm not + // sure why, but I'm leaving it here for now. + if (platform() !== "win32" || atLeastVersion("3.0")) { + describe("non-ASCII", () => { + test("emoji", () => { + return expect(rbs(`T: { "🌼" => Integer }`)).toMatchFormat(); + }); + + test("kanji", () => { + return expect(rbs(`T: { "日本語" => Integer }`)).toMatchFormat(); + }); + }); + } + + describeCases("tuple", (source) => `T: ${source}`); +}); diff --git a/test/js/rbs/record.txt b/test/js/rbs/record.txt new file mode 100644 index 00000000..d5e3a6e0 --- /dev/null +++ b/test/js/rbs/record.txt @@ -0,0 +1,3 @@ +{ foo: Integer } +{ foo: untyped, 3 => "hoge" } +{ :+ => 1 } diff --git a/test/js/rbs/tuple.txt b/test/js/rbs/tuple.txt new file mode 100644 index 00000000..7dd425e4 --- /dev/null +++ b/test/js/rbs/tuple.txt @@ -0,0 +1,3 @@ +[ ] +[untyped, nil, void] +[untyped] diff --git a/test/js/ruby/comments.test.js b/test/js/ruby/comments.test.js new file mode 100644 index 00000000..1dcea4a3 --- /dev/null +++ b/test/js/ruby/comments.test.js @@ -0,0 +1,263 @@ +import { ruby } from "../utils.js"; + +describe("comments", () => { + describe("on their own line", () => { + test("at the beginning of the file", () => { + const content = ruby(` + # this is a comment at + # the beginning of the file + + a = 1 + `); + + return expect(content).toMatchFormat(); + }); + + test("at the end of the file", () => { + const content = ruby(` + a = 1 + + # this is a comment at + # the end of the file + `); + + return expect(content).toMatchFormat(); + }); + + const commentBlocks = [ + "loop do", + "def foo", + "def self.foo", + "class Foo", + "module Foo", + "class << self", + "if foo", + "unless foo", + "while foo", + "until foo" + ]; + + describe.each(commentBlocks)("%s blocks", (start) => { + test("as the only statement", () => { + const content = ruby(` + ${start} + # this is the only statement + # inside this block + end + `); + + return expect(content).toMatchFormat(); + }); + + test("as the first statement", () => { + const content = ruby(` + ${start} + # this is the first statement + # inside this block + foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("as the last statement", () => { + const content = ruby(` + ${start} + foo + # this is the last statement + # inside this block + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("if/elsif/else/end statements", () => { + const content = ruby(` + if a + # this is the only comment in this if + elsif b + # this is the only comment in this elsif + elsif c + # this is a comment at the beginning of this elsif + 1 + elsif d + 2 + # this is a comment at the end of an elsif + else + # this is the only comment in this else + end + `); + + return expect(content).toMatchFormat(); + }); + + test("case/when/end statements", () => { + const content = ruby(` + case foo + when bar + # this is a comment at the beginning of a when + 1 + when baz + 2 + # this is a comment at the end of a when + when qux + # this is the only statement in this when + else + # this is the only statement in this else + end + `); + + return expect(content).toMatchFormat(); + }); + + test("begin/rescue/ensure/end statements", () => { + const content = ruby(` + begin + # this is the only statement in this begin + rescue FooError + # this is the only statement in this rescue + rescue BarError + # this is the first statement of this rescue + 1 + rescue BazError + 2 + # this is the last statement of this rescue + ensure + # this is the only statement in this ensure + end + `); + + return expect(content).toMatchFormat(); + }); + + /* eslint-disable no-useless-escape */ + test("end content", () => { + const content = ruby(` + a = 1 + + __END__ + /‾‾‾‾‾\ /‾‾‾‾‾\ /‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾‾‾/ /‾‾‾‾/ /‾‾‾‾‾\ + / /‾‾/ / / /‾‾/ / / /‾‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ ‾‾/ /‾‾ / /‾‾‾ / /‾‾/ / + / ‾‾‾ / / ‾‾‾_/ / _‾/ / / / / / / / _‾/ / ‾‾‾_/ + / /‾‾‾‾‾ / /‾\ \ / /__ / / / / __/ /_ / /__ / /‾\ \ + /_/ /_/ /_/ /____/ /_/ /_/ /_____/ /____/ /_/ /_/ + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("inline", () => { + test("basic", () => { + return expect("foo # this is an inline comment").toMatchFormat(); + }); + + test("commands", () => { + return expect( + `command "foo" # this is an inline comment` + ).toMatchFormat(); + }); + + test("command calls", () => { + return expect( + `command.call "foo" # this is an inline comment` + ).toMatchFormat(); + }); + }); + + describe("arrays", () => { + test("on their own lines", () => { + const content = ruby(` + [ + # these are comments + # inside of an array + foo, + # an then some more + bar + ] + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("hashes", () => { + test("on their own lines", () => { + const content = ruby(` + { + # these are comments + # inside of a hash + foo: "bar", + # and then some more + bar: "baz" + } + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("method calls", () => { + test("on their own lines", () => { + const content = ruby(` + foo.bar( + # this is a comment at the beginning of the method call + foo: bar, + # this is a comment in the middle of the method call + bar: baz + # this is a comment at the end of the method call + ) + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("causing ignored_nl", () => { + const content = ruby(` + foo.bar # comment + .baz + `); + + const expected = ruby(` + foo.bar # comment + .baz + `); + + return expect(content).toChangeFormat(expected); + }); + + describe("declaration style comments", () => { + const declarations = [ + "class Foo", + "module Foo", + "def foo", + "def self.foo", + "class << foo" + ]; + + test.each(declarations)("%s inline", (declaration) => { + const content = ruby(` + ${declaration} # :nodoc + bar + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("works with multi-byte characters", () => { + const content = ruby(` + [ + ["先生小"], # + ["小"] + ] + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/encoding.test.js b/test/js/ruby/encoding.test.js new file mode 100644 index 00000000..1d6bb806 --- /dev/null +++ b/test/js/ruby/encoding.test.js @@ -0,0 +1,19 @@ +describe("encoding", () => { + const header = "# -*- encoding: binary -*-"; + + test("comments", () => { + return expect(`${header}\n# il était`).toMatchFormat(); + }); + + test("symbol literals", () => { + return expect(`${header}\n:il_était`).toMatchFormat(); + }); + + test("string literals", () => { + return expect(`${header}\n"ひらがな"`).toMatchFormat(); + }); + + test("regexp literals", () => { + return expect(`${header}\n/ひらがな/`).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/errors.test.js b/test/js/ruby/errors.test.js new file mode 100644 index 00000000..a5e99bbb --- /dev/null +++ b/test/js/ruby/errors.test.js @@ -0,0 +1,24 @@ +import { format } from "prettier"; + +describe("errors", () => { + const cases = [ + "alias $a $1", + "self = 1", + "$` = 1", + "class foo; end", + "def foo(A) end", + "def foo($a) end", + "def foo(@a) end", + "def foo(@@a) end", + "<>" + ]; + + test.each(cases)("fails for %s", async (content) => { + try { + await format(content, { parser: "ruby", plugins: ["."] }); + expect(true).toBe(false); + } catch (error) { + expect(error.loc).toBeDefined(); + } + }); +}); diff --git a/test/js/ruby/ignore.test.js b/test/js/ruby/ignore.test.js new file mode 100644 index 00000000..f1ce1f95 --- /dev/null +++ b/test/js/ruby/ignore.test.js @@ -0,0 +1,12 @@ +import { ruby } from "../utils.js"; + +describe("ignore", () => { + test("you can ignore code blocks", () => { + const content = ruby(` + # stree-ignore + class Foo; def bar; 1+1+1; end; end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/layout.test.js b/test/js/ruby/layout.test.js new file mode 100644 index 00000000..393d5e5d --- /dev/null +++ b/test/js/ruby/layout.test.js @@ -0,0 +1,41 @@ +import { ruby } from "../utils.js"; + +describe("layout", () => { + test("turns multiple blank lines into just one blank line", () => { + return expect("1\n\n\n\n\n2").toChangeFormat("1\n\n2"); + }); + + test("turns semicolons into adjacent lines", () => { + return expect("1; 2; 3").toChangeFormat("1\n2\n3"); + }); + + test("maintains semicolons from within interpolation", () => { + return expect(`"a#{b; c}"`).toMatchFormat(); + }); + + test("handles multiple newlines at the end of the file", () => { + return expect("foo\n\n\n").toChangeFormat("foo"); + }); + + test("keeps comments in their place when nothing to attach to", () => { + const content = ruby(` + # Comment + def f + print 1 + end + + # Comment + # Comment + + def g + print 2 + end + + # Comment + # Comment + # Comment + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/alias.test.js b/test/js/ruby/nodes/alias.test.js new file mode 100644 index 00000000..df83939f --- /dev/null +++ b/test/js/ruby/nodes/alias.test.js @@ -0,0 +1,66 @@ +import { long, ruby } from "../../utils.js"; + +describe("alias", () => { + test("bare word aliases", () => { + return expect("alias foo bar").toMatchFormat(); + }); + + test("bare word operator aliases", () => { + return expect("alias << push").toMatchFormat(); + }); + + test("bare word keyword aliases", () => { + return expect("alias in within").toMatchFormat(); + }); + + test("bare word constant aliases", () => { + return expect("alias in IN").toMatchFormat(); + }); + + test("symbol aliases become bare word aliases", () => { + return expect("alias :foo :bar").toChangeFormat("alias foo bar"); + }); + + test("dynamic symbols do not get transformed (left)", () => { + return expect(`alias :"foo" :bar`).toChangeFormat(`alias :"foo" bar`); + }); + + test("dynamic symbols do not get transformed (right)", () => { + return expect(`alias :foo :"bar"`).toChangeFormat(`alias foo :"bar"`); + }); + + test("global aliases", () => { + return expect("alias $foo $bar").toMatchFormat(); + }); + + test("handles long symbols", () => { + const expected = ruby(` + alias ${long} + bar + `); + + return expect(`alias ${long} bar`).toChangeFormat(expected); + }); + + test("handles comments on the right node", () => { + return expect("alias foo bar # baz").toMatchFormat(); + }); + + test("handles comments on the left node", () => { + const content = ruby(` + alias foo # baz + bar + `); + + return expect(content).toMatchFormat(); + }); + + test("handles comments on both nodes", () => { + const content = ruby(` + alias foo # foo + bar # bar + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/aref.test.js b/test/js/ruby/nodes/aref.test.js new file mode 100644 index 00000000..aa7d7cb4 --- /dev/null +++ b/test/js/ruby/nodes/aref.test.js @@ -0,0 +1,35 @@ +import { ruby } from "../../utils.js"; + +describe("aref", () => { + test("literal reference", () => { + return expect("array[5]").toMatchFormat(); + }); + + test("dynamic reference", () => { + return expect("array[idx]").toMatchFormat(); + }); + + test("reference with comment", () => { + return expect("array[idx] # foo").toMatchFormat(); + }); + + test("literal assignment", () => { + return expect("array[5] = 6").toMatchFormat(); + }); + + test("dynamic assignment", () => { + return expect("array[idx] = 6").toMatchFormat(); + }); + + test("comments within assignment", () => { + const contents = ruby(` + array = %w[foo bar] + array[1] = [ + # abc + %w[abc] + ] + `); + + return expect(contents).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/arrays.test.js b/test/js/ruby/nodes/arrays.test.js new file mode 100644 index 00000000..e54d567f --- /dev/null +++ b/test/js/ruby/nodes/arrays.test.js @@ -0,0 +1,161 @@ +import { long, ruby } from "../../utils.js"; + +describe("array", () => { + test("empty arrays", () => { + return expect("[]").toMatchFormat(); + }); + + test("basic formatting", () => { + return expect("[1, 2, 3]").toMatchFormat(); + }); + + test("does not transform single string arrays", () => { + return expect(`["a"]`).toMatchFormat(); + }); + + test("does not transform single symbol arrays", () => { + return expect("[:a]").toMatchFormat(); + }); + + test("transforms basic string arrays", () => { + return expect(`["a", "b", "c", "d", "e"]`).toChangeFormat("%w[a b c d e]"); + }); + + test("does not transform string arrays with interpolation", () => { + return expect(`["a", "#{b}", "c"]`).toMatchFormat(); + }); + + test("does not transform string arrays with spaces", () => { + return expect(`["a", "b c", "d", "e"]`).toMatchFormat(); + }); + + test("does not transform string arrays with tabs", () => { + return expect(`["a", "b\\tc", "d", "e"]`).toMatchFormat(); + }); + + test("does not transform string arrays with newlines", () => { + return expect(`["a", "b\\nc", "d", "e"]`).toMatchFormat(); + }); + + test("does not transform string arrays with carriage returns", () => { + return expect(`["a", "b\\rc", "d", "e"]`).toMatchFormat(); + }); + + test("does not transform string arrays with interpolation", () => { + return expect(`["a", "b#{c}d", "e"]`).toMatchFormat(); + }); + + test("does not transform string arrays with brackets", () => { + return expect(`["a [] b", "c [] d"]`).toMatchFormat(); + }); + + test("transforms basic symbol arrays", () => { + return expect("[:a, :b, :c]").toChangeFormat("%i[a b c]"); + }); + + test("does not transform symbol arrays with dynamic symbols", () => { + return expect(`[:"a + b"]`).toMatchFormat(); + }); + + test("handles splats", () => { + return expect("[1, 2, *[3, 4], 5, 6]").toMatchFormat(); + }); + + test("breaks appropriately", () => { + const contents = ruby(` + [ + ${long}, + ${long}, + [ + ${long}, + ${long}, + ${long} + ] + ] + `); + + return expect(contents).toMatchFormat(); + }); + + test("breaking maintains calls on the end", () => { + return expect(`[${long}].freeze`).toChangeFormat(`[\n ${long}\n].freeze`); + }); + + describe("heredocs", () => { + test("as the first value", () => { + const content = ruby(` + [<<~HERE, foo] + this is the heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("as the last value", () => { + const content = ruby(` + [foo, <<~HERE] + this is the heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with splats in the array", () => { + const content = ruby(` + [foo, *bar, baz, <<~HERE] + this is the heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("with leading comments but none in body", () => { + const content = ruby(` + # leading + [] + `); + + return expect(content).toMatchFormat(); + }); + + test("with leading comments and comments in the body", () => { + const content = ruby(` + # leading + [ + # inside + # body + ] + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments just in the body", () => { + const content = ruby(` + [ + # inside + # body + ] + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments just outside but attached", () => { + const content = ruby(` + foo( + [] # comment comment + ) + `); + + return expect(content).toMatchFormat(); + }); + + test.each(["%w", "%W", "%i", "%I"])("%s special array literals", (start) => + expect(`${start}[a b c]`).toMatchFormat() + ); +}); diff --git a/test/js/ruby/nodes/assign.test.js b/test/js/ruby/nodes/assign.test.js new file mode 100644 index 00000000..f8a1254e --- /dev/null +++ b/test/js/ruby/nodes/assign.test.js @@ -0,0 +1,149 @@ +import { long, ruby } from "../../utils.js"; + +describe("assign", () => { + describe("single assignment", () => { + test("basic", () => { + return expect("a = 1").toMatchFormat(); + }); + + test("multiline", () => { + const content = ruby(` + a = + begin + 1 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("other operator", () => { + return expect("a ||= b").toMatchFormat(); + }); + }); + + test("heredoc", () => { + const content = ruby(` + text = <<-TEXT + abcd + TEXT + `); + + return expect(content).toMatchFormat(); + }); + + describe("breaking", () => { + test("inline becomes multi line", () => { + return expect(`${long} = ${long}`).toChangeFormat(`${long} =\n ${long}`); + }); + + test("arrays don't get force indented", () => { + return expect(`a = [${long}, ${long}, ${long}]`).toChangeFormat( + ruby(` + a = [ + ${long}, + ${long}, + ${long} + ] + `) + ); + }); + + test("hashes don't get force indented", () => { + return expect( + `a = { a: ${long}, b: ${long}, c: ${long} }` + ).toChangeFormat( + ruby(` + a = { + a: + ${long}, + b: + ${long}, + c: + ${long} + } + `) + ); + }); + + describe("assignments from quotewords and similar", () => { + const cases = ["w", "W", "i", "I"]; + + test.each(cases)("x = %s[...] is not force-indented", (literal) => { + return expect(`a = %${literal}[${long} ${long}]`).toChangeFormat( + ruby(` + a = %${literal}[ + ${long} + ${long} + ] + `) + ); + }); + }); + + test("chained methods on array literals don't get oddly indented", () => { + return expect(`a = [${long}].freeze`).toChangeFormat( + ruby(` + a = [ + ${long} + ].freeze + `) + ); + }); + + test("chained methods on hash literals don't get oddly indented", () => { + return expect(`a = { a: ${long} }.freeze`).toChangeFormat( + ruby(` + a = { + a: + ${long} + }.freeze + `) + ); + }); + + describe("assignment operators", () => { + // some but not all + const operators = ["||", "&&", "+", "*", "%", "**", "<<"]; + + test.each(operators)("array %s= [...] is not force-indented", (op) => { + return expect(`a ${op}= [${long}, ${long}, ${long}]`).toChangeFormat( + ruby(` + a ${op}= [ + ${long}, + ${long}, + ${long} + ] + `) + ); + }); + + test.each(operators)("hash %s= { ... } is not force-indented", (op) => { + return expect( + `a ${op}= { a: ${long}, b: ${long}, c: ${long} }` + ).toChangeFormat( + ruby(` + a ${op}= { + a: + ${long}, + b: + ${long}, + c: + ${long} + } + `) + ); + }); + }); + }); + + describe("constants", () => { + test("assigning to constant", () => { + return expect(`Pret::TIER = "config"`).toMatchFormat(); + }); + + test("assigning to top level constants", () => { + return expect(`::PRETTIER = "config"`).toMatchFormat(); + }); + }); +}); diff --git a/test/js/ruby/nodes/binary.test.js b/test/js/ruby/nodes/binary.test.js new file mode 100644 index 00000000..2ce05d6a --- /dev/null +++ b/test/js/ruby/nodes/binary.test.js @@ -0,0 +1,38 @@ +import { long, ruby } from "../../utils.js"; + +describe("binary", () => { + test("single line", () => { + return expect("foo && bar && baz").toMatchFormat(); + }); + + test("multi line", () => { + return expect(`${long} && ${long} && ${long}`).toChangeFormat( + `${long} &&\n ${long} &&\n ${long}` + ); + }); + + test("no indent on the right", () => { + const content = `foo << [${long}]`; + const expected = ruby(` + foo << [ + ${long} + ] + `); + + return expect(content).toChangeFormat(expected); + }); + + test("with heredoc and comment", () => { + const content = ruby(` + foo << <<~HERE # comment + bar + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("no spaces for **", () => { + return expect("a**b").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/blocks.test.js b/test/js/ruby/nodes/blocks.test.js new file mode 100644 index 00000000..8d4c9d8f --- /dev/null +++ b/test/js/ruby/nodes/blocks.test.js @@ -0,0 +1,199 @@ +import { long, ruby } from "../../utils.js"; + +describe("blocks", () => { + test("empty", () => { + return expect("loop {}").toMatchFormat(); + }); + + test("single line non-breaking", () => { + return expect("loop { 1 }").toMatchFormat(); + }); + + test("single line breaking", () => { + return expect(`loop { ${long} }`).toChangeFormat(`loop do\n ${long}\nend`); + }); + + test("multi line non-breaking", () => { + return expect("loop do\n 1\nend").toChangeFormat("loop { 1 }"); + }); + + test("multi-line breaking", () => { + return expect(`loop do\n ${long}\nend`).toMatchFormat(); + }); + + test("multi-line with comment", () => { + return expect("loop do\n # foobar\nend").toMatchFormat(); + }); + + test("multi-line on command, no body", () => { + return expect(`command "foobar" do\nend`).toMatchFormat(); + }); + + test("multi-line on command call, no body", () => { + return expect(`command.call "foobar" do\nend`).toMatchFormat(); + }); + + test("multi-line on command, with body", () => { + return expect(`command "foobar" do\n foo\nend`).toMatchFormat(); + }); + + test("multi-line on command call, with body", () => { + return expect(`command.call "foobar" do\n foo\nend`).toMatchFormat(); + }); + + test("blocks nested inside commands use braces", () => { + const expected = ruby(` + foo ${long} { + ${long} + }.bar + `); + + return expect(`foo ${long} { ${long} }.bar`).toChangeFormat(expected); + }); + + test("breaking maintains calls on the end", () => { + const content = ruby(` + method.each do |foo| + bar + baz + end.to_i + `); + + const expected = ruby(` + method + .each do |foo| + bar + baz + end + .to_i + `); + + return expect(content).toChangeFormat(expected); + }); + + test("doesn't do weird things with comments", () => { + const content = ruby(` + foo.each do |bar| + # comment + bar.baz + bar.baz + end + `); + + return expect(content).toMatchFormat(); + }); + + describe("for loops", () => { + test("for loops", () => { + const content = ruby(` + for i in [1, 2, 3] + p i + end + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple variables", () => { + const content = ruby(` + for a, b in [[1, 2], [3, 4]] + p i + end + `); + + return expect(content).toMatchFormat(); + }); + + test("optional do keyword", () => { + const content = ruby(` + a do + # comment + for b in c do + puts b + end + end + `); + + const expected = ruby(` + a do + # comment + for b in c + puts b + end + end + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + test("excessed_comma nodes", () => { + return expect("proc { |x,| }").toMatchFormat(); + }); + + describe("args", () => { + test("no body", () => { + return expect("loop { |i| }").toMatchFormat(); + }); + + test("single line non-breaking", () => { + return expect("loop { |i| 1 }").toMatchFormat(); + }); + + test("single line breaking", () => { + return expect(`loop { |i| ${long} }`).toChangeFormat( + `loop do |i|\n ${long}\nend` + ); + }); + + test("multi-line non-breaking", () => { + return expect("loop do |i|\n i\nend").toChangeFormat("loop { |i| i }"); + }); + + test("multi-line breaking", () => { + return expect(`loop do |i|\n ${long}\nend`).toMatchFormat(); + }); + + test("block-local args", () => { + return expect("loop { |i; j| 1 }").toMatchFormat(); + }); + + test("splat", () => { + return expect("loop { |*| i }").toMatchFormat(); + }); + + test("destructure", () => { + return expect("loop { |(a, b)| i }").toMatchFormat(); + }); + + test("lots of args types", () => { + return expect("loop { |a, (b, c), d, *e| i }").toMatchFormat(); + }); + + test("does not split up args inside pipes", () => { + return expect(`loop do |${long} = 1, a${long} = 2|\nend`).toMatchFormat(); + }); + }); + + // https://github.com/prettier/plugin-ruby/issues/989 + test("comments on a do block", () => { + const content = ruby(` + RSpec.describe Api::V2::OAuth::TokensController, type: :api do # rubocop:disable RSpec/FilePath + foo + end + `); + + return expect(content).toMatchFormat(); + }); + + // https://github.com/prettier/plugin-ruby/issues/1042 + test("comments on the do block without a command", () => { + const content = ruby(` + let!(:some_variable) do # comment text + nil + end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/break.test.js b/test/js/ruby/nodes/break.test.js new file mode 100644 index 00000000..10ba00f9 --- /dev/null +++ b/test/js/ruby/nodes/break.test.js @@ -0,0 +1,38 @@ +import { ruby } from "../../utils.js"; + +describe("break", () => { + test("empty break", () => { + return expect("break").toMatchFormat(); + }); + + test("break with one argument, no parens", () => { + return expect("break 1").toMatchFormat(); + }); + + test("break with parens drops parens", () => { + return expect("break(1)").toChangeFormat("break 1"); + }); + + test("break with multiple arguments", () => { + return expect("break 1, 2, 3").toMatchFormat(); + }); + + test("keeps parens for multiple statements", () => { + const expected = ruby(` + break( + a = 1 + a == 1 + ) + `); + + return expect("break(a = 1; a == 1)").toChangeFormat(expected); + }); + + test("keeps parens for _mod nodes", () => { + return expect("break(1 if true)").toMatchFormat(); + }); + + test("works with comments", () => { + return expect("break # foo").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/calls.test.js b/test/js/ruby/nodes/calls.test.js new file mode 100644 index 00000000..1b57328e --- /dev/null +++ b/test/js/ruby/nodes/calls.test.js @@ -0,0 +1,206 @@ +import { long, ruby } from "../../utils.js"; + +describe("calls", () => { + test("simple calls", () => { + const content = `posts.active.where("created_at > ?", 1.year.ago)`; + + return expect(content).toMatchFormat(); + }); + + test("short chains", () => { + return expect("foo.bar.baz qux").toMatchFormat(); + }); + + test("chain methods", () => { + const before = ruby(` + aaaaaaaaaa.bbbbbbbbbb.cccccccccc.dddddddddd(foo, bar).eeeeeeeeee.ffffffffff.gggggggggg.hhhhhhhhhh + `); + + const after = ruby(` + aaaaaaaaaa + .bbbbbbbbbb + .cccccccccc + .dddddddddd(foo, bar) + .eeeeeeeeee + .ffffffffff + .gggggggggg + .hhhhhhhhhh + `); + + return expect(before).toChangeFormat(after); + }); + + test("chains of methods with one with arguments right at the top", () => { + const content = ruby(` + aaa.bbb.ccc.ddd.eee.merge( + ${long.slice(0, 30)}: "aaa", + ${long.slice(0, 31)}: "bbb" + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("chains of methods with a block right at the top", () => { + const block = long.slice(0, 60); + const content = ruby(` + aaa.bbb.ccc.ddd.eee do + ${block} + end + `); + + return expect(content).toMatchFormat(); + }); + + test("tons of calls that fit on one line", () => { + const content = "a.b.c.d.e.f.g.h.i.j.k.l.m.n.o.p.q.r.s.t.u.v.w.x.y.z"; + + return expect(content).toMatchFormat(); + }); + + test("chains which contain a .where.not", () => { + const content = ruby(` + Customer + .active + .where(foo: "bar") + .where.not(banned_at: nil) + .order(created_at: "desc") + .limit(10) + `); + + return expect(content).toMatchFormat(); + }); + + describe("within sig blocks", () => { + test("basic chains", () => { + const content = ruby(` + sig do + params(contacts: Contact::ActiveRecord_Relation).returns( + Customer::ActiveRecord_Relation + ) + end + `); + + return expect(content).toMatchFormat(); + }); + + test("chains with other methods", () => { + const content = ruby(` + sig do + overridable + .params(contacts: Contact::ActiveRecord_Relation) + .returns(Customer::ActiveRecord_Relation) + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("chains with blocks mixed in", () => { + const content = ruby(` + Model + .dataset + .eager(:table1) + .join(:second_table_name.as(:table2), %i[album_id artist_id]) + .where(table1__artist_id: artists.map(&:id)) + .where { table1__date > Time.now - 31.days } + .where { table2__date > table1_date } + .exclude(table2__album_id: :table1__album_id) + .select_all(:table1) + `); + + return expect(content).toMatchFormat(); + }); + + test("no explicit call doesn't add call", () => { + return expect("a.(1, 2, 3)").toMatchFormat(); + }); + + test("explicit call maintains call", () => { + return expect("a.call(1, 2, 3)").toMatchFormat(); + }); + + test("double bang with a special operator on a call", () => { + return expect("!!object&.topic_list").toMatchFormat(); + }); + + test("bang with a special operator on a command_call", () => { + return expect(`!domain&.include? "@"`).toMatchFormat(); + }); + + test("#call shorthand does not eliminate empty parentheses", () => { + return expect("Foo.new.()").toMatchFormat(); + }); + + test("methods that look like constants do not eliminate empty parens", () => { + return expect("Foo()").toMatchFormat(); + }); + + test("call chains with no indent on the first receiver", () => { + const item = long.slice(0, 30); + const content = `result = [${item}, ${item}, ${item}].map(&:foo?).bbb.ccc`; + + const expected = ruby(` + result = [ + ${item}, + ${item}, + ${item} + ].map(&:foo?).bbb.ccc + `); + + return expect(content).toChangeFormat(expected); + }); + + test("chained method_add_arg after a block", () => { + const content = ruby(` + a.b c do + end.d e, f + `); + + return expect(content).toMatchFormat(); + }); + + test("comments in a method chain get printed correctly", () => { + // https://github.com/prettier/plugin-ruby/issues/943 + const content = ruby(` + Organization.includes( + :users, + :venues + ) + .where(id: org_ids) + .flatten. + # first remove rows with duplicate names + uniq { |contact| "#{contact[:first_name]}#{contact[:last_name]}#{contact[:org_name]}" }. + # then remove remaining rows with duplicate emails + uniq { |contact| contact[:email] } + .tap { |res| + CSV.open(OUTPUT_PATH, "wb") { |csv| + csv << HEADERS + res.each { |d| csv << d.values } + } + } + `); + + const expected = ruby(` + Organization + .includes(:users, :venues) + .where(id: org_ids) + .flatten. + # first remove rows with duplicate names + uniq do |contact| + "#{contact[:first_name]}#{contact[:last_name]}#{contact[:org_name]}" + end. + # then remove remaining rows with duplicate emails + uniq { |contact| contact[:email] } + .tap do |res| + CSV.open(OUTPUT_PATH, "wb") do |csv| + csv << HEADERS + res.each { |d| csv << d.values } + end + end + `); + + return expect(content).toChangeFormat(expected); + }); +}); diff --git a/test/js/ruby/nodes/case.test.js b/test/js/ruby/nodes/case.test.js new file mode 100644 index 00000000..f6efaa5d --- /dev/null +++ b/test/js/ruby/nodes/case.test.js @@ -0,0 +1,106 @@ +import { long, ruby } from "../../utils.js"; + +describe("case", () => { + test("empty case", () => { + const content = ruby(` + case + when a + 1 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("single when", () => { + const content = ruby(` + case a + when b + 1 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple predicates, one when", () => { + const content = ruby(` + case a + when b, c + 1 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking with multiple predicates, one when", () => { + const content = ruby(` + case foo + when "${long}", + "a${long}", + "b${long}" + bar + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking with multiple predicates, each one not too long", () => { + const content = ruby(` + case foo + when "${long.slice(0, 40)}", "${long.slice(0, 40)}" + bar + end + `); + + const expected = ruby(` + case foo + when "${long.slice(0, 40)}", + "${long.slice(0, 40)}" + bar + end + `); + + return expect(content).toChangeFormat(expected); + }); + + test("multiple consecutive whens", () => { + const content = ruby(` + case a + when b + when c + 1 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("basic multiple branches", () => { + const content = ruby(` + case a + when b + 1 + when c + 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("else clauses", () => { + const content = ruby(` + case a + when b + 1 + else + 2 + end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/class.test.js b/test/js/ruby/nodes/class.test.js new file mode 100644 index 00000000..ba917ba9 --- /dev/null +++ b/test/js/ruby/nodes/class.test.js @@ -0,0 +1,130 @@ +import { long, ruby } from "../../utils.js"; + +describe("class", () => { + test("basic nesting", () => { + const content = ruby(` + module Pret + module Tier + class Plugin + end + + module Ruby + end + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("inheritance", () => { + const content = ruby(` + module Prettier + class Ruby < Object + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking class name", () => { + return expect(`class P${long}; end`).toChangeFormat(`class P${long}\nend`); + }); + + test("breaking module name", () => { + return expect(`module P${long}; end`).toChangeFormat( + `module P${long}\nend` + ); + }); + + test("class push blocks", () => { + const content = ruby(` + class << Prettier + def foo + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple access controls", () => { + const content = ruby(` + class Prettier + public + + def public_method + # some method body + end + + protected + + def protected_method + # some method body + end + + private + + def private_method + # some method body + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("method helper", () => { + const content = ruby(` + class Prettier + helper def foo + # some method body + end + end + `); + + return expect(content).toMatchFormat(); + }); + + describe.each(["public", "protected", "private"])( + "%s access control", + (keyword) => { + test("basic", () => { + const content = ruby(` + class Prettier + ${keyword} + + def method + # some method body + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("inline", () => { + const content = ruby(` + class Prettier + ${keyword} def method + # some method body + end + end + `); + + return expect(content).toMatchFormat(); + }); + } + ); + + describe("constant reference", () => { + test("regular", () => { + return expect("Pret::Tier::Ruby").toMatchFormat(); + }); + + test("top-level", () => { + return expect("::Pret::Tier::Ruby").toMatchFormat(); + }); + }); +}); diff --git a/test/js/ruby/nodes/conditionals.test.js b/test/js/ruby/nodes/conditionals.test.js new file mode 100644 index 00000000..dc8db071 --- /dev/null +++ b/test/js/ruby/nodes/conditionals.test.js @@ -0,0 +1,666 @@ +import { long, ruby, atLeastVersion } from "../../utils.js"; + +describe("conditionals", () => { + describe("not operator", () => { + // from ruby test/ruby/test_not.rb + test("not operator, empty parens", () => { + return expect("assert_equal(true, (not ()))").toMatchFormat(); + }); + + test("not operator from within a ternary adds parens", () => { + return expect("a ? not(b) : c").toMatchFormat(); + }); + + test("not operator from within an if/else adds parens", () => { + const content = ruby(` + if a + not b + else + c + end + `); + + return expect(content).toChangeFormat("a ? not(b) : c"); + }); + }); + + describe("modifiers", () => { + describe.each(["if", "unless"])("%s keyword", (keyword) => { + test("when modifying an assignment expression", () => { + const content = `text = "${long}" ${keyword} text`; + const expected = ruby(` + text = + "${long}" ${keyword} text + `); + + return expect(content).toChangeFormat(expected); + }); + + test("when modifying an abbreviated assignment expression", () => { + const content = `text ||= "${long}" ${keyword} text`; + const expected = ruby(` + text ||= + "${long}" ${keyword} text + `); + + return expect(content).toChangeFormat(expected); + }); + + test("when modifying an expression with an assignment descendant", () => { + const content = `true && (text = "${long}") ${keyword} text`; + const expected = ruby(` + true && + ( + text = + "${long}" + ) ${keyword} text + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + test("does not insert double modifiers on a single line", () => { + const content = ruby(` + if a + do_something unless b + end + `); + const expected = ruby(` + if a + do_something unless b + end + `); + + return expect(content).toChangeFormat(expected); + }); + + test("does not insert double modifiers on a single line for nested conditionals", () => { + const content = ruby(` + if a + unless b + do_something + end + end + `); + const expected = ruby(` + if a + do_something unless b + end + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + describe("when inline allowed", () => { + describe.each(["if", "unless"])("%s keyword", (keyword) => { + test("inline stays", () => { + return expect(`1 ${keyword} a`).toMatchFormat(); + }); + + test("multi line changes", () => { + return expect(`${keyword} a\n 1\nend`).toChangeFormat( + `1 ${keyword} a` + ); + }); + + test("inline breaking changes", () => { + return expect(`${long} ${keyword} ${long}`).toChangeFormat( + `${keyword} ${long}\n ${long}\nend` + ); + }); + + test("multi line breaking stays", () => { + return expect(`${keyword} ${long}\n ${long}\nend`).toMatchFormat(); + }); + + test("not operator", () => { + return expect(`b ${keyword} not a`).toMatchFormat(); + }); + + test("empty first body", () => { + const content = ruby(` + ${keyword} a + end + `); + + return expect(content).toMatchFormat(); + }); + + test("empty first body with present second body", () => { + const content = ruby(` + ${keyword} a + else + b + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment in body", () => { + const content = ruby(` + ${keyword} a + # comment + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment in body with question mark method", () => { + const content = ruby(` + ${keyword} a? + # comment + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment on node in body", () => { + const content = ruby(` + ${keyword} a + break # comment + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaks if the predicate is an assignment", () => { + const content = ruby(` + array.each do |element| + ${keyword} index = difference.index(element) + difference.delete_at(index) + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaks if the predicate is an op assignment", () => { + const content = ruby(` + array.each do |element| + ${keyword} index ||= difference.index(element) + difference.delete_at(index) + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("align long predicates", () => { + return expect(`foo ${keyword} ${long} || ${long}a`).toChangeFormat( + ruby(` + ${keyword} ${long} || + ${Array(keyword.length).fill("").join(" ")}${long}a + foo + end + `) + ); + }); + + test("wraps single lines in parens when assigning", () => { + return expect( + `hash[:key] = ${keyword} false then :value end` + ).toChangeFormat(`hash[:key] = (:value ${keyword} false)`); + }); + + test("wraps inline version with calls", () => { + const content = ruby(` + if true + false + end.to_s + `); + + return expect(content).toChangeFormat("(false if true).to_s"); + }); + + test("wraps inline version within binary", () => { + const content = ruby(` + if foo + bar + end || baz + `); + + return expect(content).toChangeFormat("(bar if foo) || baz"); + }); + }); + }); + + describe("ternaries", () => { + test("non-breaking", () => { + return expect("a ? 1 : 2").toMatchFormat(); + }); + + test("breaking", () => { + return expect(`a ? ${long} : ${long}`).toChangeFormat( + ruby(` + if a + ${long} + else + ${long} + end + `) + ); + }); + + test("transform from if/else", () => { + const content = ruby(` + if a + 1 + else + 2 + end + `); + + return expect(content).toChangeFormat("a ? 1 : 2"); + }); + + test("transform for unless/else", () => { + const content = ruby(` + unless a + 1 + else + 2 + end + `); + + return expect(content).toChangeFormat("a ? 2 : 1"); + }); + + test("adds parens if inside of a call", () => { + const content = ruby(` + if a + 1 + else + 2 + end.to_s + `); + + return expect(content).toChangeFormat("(a ? 1 : 2).to_s"); + }); + + test("does not add parens if it breaks", () => { + const content = ruby(` + if a + ${long} + else + 2 + end.to_s + `); + + return expect(content).toMatchFormat(); + }); + + test("adds parens if inside of a binary", () => { + const content = ruby(` + if a + 1 + else + 2 + end + 1 + `); + + return expect(content).toChangeFormat("(a ? 1 : 2) + 1"); + }); + + test("adds parens if within a command", () => { + const content = `foo baz ? ${long} : ${long}`; + const expected = ruby(` + foo( + if baz + ${long} + else + ${long} + end + ) + `); + + return expect(content).toChangeFormat(expected); + }); + + test("does not add parens if within a command_call non-breaking", () => { + return expect("foo.bar baz ? foo : bar").toMatchFormat(); + }); + + test("adds parens if within a command_call", () => { + const content = `foo.bar baz ? ${long} : ${long}`; + const expected = ruby(` + foo.bar( + if baz + ${long} + else + ${long} + end + ) + `); + + return expect(content).toChangeFormat(expected); + }); + + describe("unable to transform", () => { + test("breaking", () => { + const content = ruby(` + if a + ${long} + else + ${long} + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command in if body", () => { + const content = ruby(` + if a + b 1 + else + b(2) + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command in else body", () => { + const content = ruby(` + if a + b(1) + else + b 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command call in if body", () => { + const content = ruby(` + if a + b.b 1 + else + b(2) + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command call in else body", () => { + const content = ruby(` + if a + b(1) + else + b.b 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("heredoc in if body", () => { + const content = ruby(` + if a + <<~HEREDOC + a + b + HEREDOC + else + b + end + `); + + return expect(content).toMatchFormat(); + }); + + test("heredoc in else body", () => { + const content = ruby(` + if a + a + else + <<~HEREDOC + a + b + HEREDOC + end + `); + + return expect(content).toMatchFormat(); + }); + + test("nested conditional in if body", () => { + const content = ruby(` + if a + if b + c + else + d + end + else + b + end + `); + + const expected = ruby(` + if a + b ? c : d + else + b + end + `); + + return expect(content).toChangeFormat(expected); + }); + + test("nested conditional in else body", () => { + const content = ruby(` + if a + b + else + if c + d + else + b + end + end + `); + const expected = ruby(` + if a + b + else + c ? d : b + end + `); + + return expect(content).toChangeFormat(expected); + }); + + test("nested ternary in if body", () => { + const content = ruby(` + if a + b ? c : d + end + `); + + return expect(content).toMatchFormat(); + }); + + test("nested ternary in else body", () => { + const content = ruby(` + if a + b + else + c ? d : e + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command with argument predicate", () => { + const content = ruby(` + if a b + 1 + else + 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("command call with argument predicate", () => { + const content = ruby(` + if a.foo? bar + 1 + else + 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("align long predicates", () => { + return expect(`${long} || ${long}a ? foo : bar`).toChangeFormat( + ruby(` + if ${long} || + ${long}a + foo + else + bar + end + `) + ); + }); + + test("lower precendence operators", () => { + const content = ruby(` + if x.nil? + puts "nil" and return + else + x + end + `); + + return expect(content).toMatchFormat(); + }); + + test("assign nodes in predicate", () => { + const content = ruby(` + if x = 1 + y + else + z + end + `); + + return expect(content).toMatchFormat(); + }); + + test("opassign nodes in predicate", () => { + const content = ruby(` + if x ||= 1 + y + else + z + end + `); + + return expect(content).toMatchFormat(); + }); + + test("cannot transform with multiple statements", () => { + const content = ruby(` + if a + 1 + 2 + else + 3 + end + `); + + return expect(content).toMatchFormat(); + }); + }); + }); + + describe("if/elsif/else chains", () => { + test("basic", () => { + const content = ruby(` + if a + 1 + elsif b + 2 + end + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple clauses", () => { + const content = ruby(` + if a + 1 + elsif b + 2 + elsif c + 3 + else + 4 + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe.each(["if", "unless"])("add parens when necessary %s", (keyword) => { + test("args", () => { + return expect(`[${keyword} foo? then bar end]`).toChangeFormat( + `[(bar ${keyword} foo?)]` + ); + }); + + test("assign", () => { + return expect(`foo = ${keyword} bar? then baz end`).toChangeFormat( + `foo = (baz ${keyword} bar?)` + ); + }); + + test("assoc", () => { + return expect(`{ foo: ${keyword} bar? then baz end }`).toChangeFormat( + `{ foo: (baz ${keyword} bar?) }` + ); + }); + + test("massign", () => { + return expect(`f, o, o = ${keyword} bar? then baz end`).toChangeFormat( + `f, o, o = (baz ${keyword} bar?)` + ); + }); + + test("opassign", () => { + return expect(`foo ||= ${keyword} bar? then baz end`).toChangeFormat( + `foo ||= (baz ${keyword} bar?)` + ); + }); + }); + + if (atLeastVersion("3.0")) { + test.each(["if", "unless"])("%s with pattern matching", (keyword) => { + const content = ruby(` + user = { role: "admin", login: "matz" } + puts "admin: #{name}" ${keyword} user in { role: "admin", name: } + `); + + return expect(content).toMatchFormat(); + }); + } +}); diff --git a/test/js/ruby/nodes/defined.test.js b/test/js/ruby/nodes/defined.test.js new file mode 100644 index 00000000..3faf4b8b --- /dev/null +++ b/test/js/ruby/nodes/defined.test.js @@ -0,0 +1,29 @@ +import { long } from "../../utils.js"; + +describe("defined", () => { + test("no parens", () => { + return expect("defined? a").toChangeFormat("defined?(a)"); + }); + + test("parens", () => { + return expect("defined?(a)").toMatchFormat(); + }); + + test("breaks on long identifier, no parens", () => { + return expect(`defined? ${long}`).toChangeFormat(`defined?(\n ${long}\n)`); + }); + + test("breaks on long identifier, with parens", () => { + return expect(`defined?(${long})`).toChangeFormat( + `defined?(\n ${long}\n)` + ); + }); + + test("breaking keeps breaking", () => { + return expect(`defined?(\n ${long}\n)`).toMatchFormat(); + }); + + test("unnecessary breaking reverts to inline", () => { + return expect("defined?(\n a\n)").toChangeFormat("defined?(a)"); + }); +}); diff --git a/test/js/ruby/nodes/embdoc.test.js b/test/js/ruby/nodes/embdoc.test.js new file mode 100644 index 00000000..9d3e1d2a --- /dev/null +++ b/test/js/ruby/nodes/embdoc.test.js @@ -0,0 +1,45 @@ +import { ruby } from "../../utils.js"; + +describe("embdoc", () => { + test("basic embdocs", () => { + const content = ruby(` + =begin + this is + + some really + + long documentation + that is contained + in an embdoc + =end + `); + + return expect(content).toMatchFormat(); + }); + + test("within a class", () => { + const content = ruby(` + class Foo + =begin + this is an embdoc inside a class + =end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("within a nested class", () => { + const content = ruby(` + module Foo + class Foo + =begin + this is an embdoc even more indented + =end + end + end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/field.test.js b/test/js/ruby/nodes/field.test.js new file mode 100644 index 00000000..2492c093 --- /dev/null +++ b/test/js/ruby/nodes/field.test.js @@ -0,0 +1,13 @@ +describe("field", () => { + test("basic", () => { + return expect("foo.x = 1").toMatchFormat(); + }); + + test("replaces :: with .", () => { + return expect("foo::x = 1").toChangeFormat("foo.x = 1"); + }); + + test("with lonely operator", () => { + return expect("foo&.x = 1").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/hashes.test.js b/test/js/ruby/nodes/hashes.test.js new file mode 100644 index 00000000..a9ecdc85 --- /dev/null +++ b/test/js/ruby/nodes/hashes.test.js @@ -0,0 +1,257 @@ +import { long, ruby } from "../../utils.js"; + +describe("hash", () => { + test("empty", () => { + return expect("{}").toMatchFormat(); + }); + + test("empty with comments", () => { + const content = ruby(` + { + # foo + # bar + } + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking", () => { + const content = ruby(` + { + ${long}: + ${long}, + ${long}: { + ${long}: + ${long} + } + } + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking maintains calls on the end", () => { + return expect(`{ a: ${long} }.freeze`).toChangeFormat( + `{\n a:\n ${long}\n}.freeze` + ); + }); + + describe("heredocs as values", () => { + test("as the first value", () => { + const content = ruby(` + { foo: <<~HERE, bar: "bar" } + this is the heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("as the last value", () => { + const content = ruby(` + { foo: "foo", bar: <<~HERE } + this is the heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("when exceeding line length", () => { + const content = ruby(` + { foo: "${long}", bar: <<~HERE } + this is the heredoc + HERE + `); + + const expected = ruby(` + { + foo: + "${long}", + bar: <<~HERE + this is the heredoc + HERE + } + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + describe("dynamic string keys", () => { + test("basic", () => { + return expect(`{ "foo": "bar" }`).toChangeFormat(`{ foo: "bar" }`); + }); + + test("with interpolation", () => { + return expect(`{ "#{1 + 1}": 2 }`).toMatchFormat(); + }); + }); + + describe("bare assoc hash", () => { + test("commands", () => { + return expect("foobar alpha: alpha, beta: beta").toMatchFormat(); + }); + + test("command calls", () => { + return expect("foo.bar alpha: alpha, beta: beta").toMatchFormat(); + }); + + test("calls", () => { + return expect("foobar(alpha: alpha, beta: beta)").toMatchFormat(); + }); + + test("breaks contents and parens together", () => { + const content = ruby(` + foobar(key1: ${long.slice(0, 32)}, key2: ${long.slice(0, 32)}) + `); + + const expected = ruby(` + foobar( + key1: ${long.slice(0, 32)}, + key2: ${long.slice(0, 32)} + ) + `); + + return expect(content).toChangeFormat(expected); + }); + }); + + describe("when hash labels allowed", () => { + test("hash labels stay", () => { + return expect(`{ a: "a", b: "b", c: "c" }`).toMatchFormat(); + }); + + test("hash rockets get replaced", () => { + return expect(`{ :a => "a", :b => "b", :c => "c" }`).toChangeFormat( + `{ a: "a", b: "b", c: "c" }` + ); + }); + + test("hash rockets stay when needed", () => { + return expect("{ Foo => 1, Bar => 2 }").toMatchFormat(); + }); + + test("ending in equals stays", () => { + return expect(`{ :foo= => "bar" }`).toMatchFormat(); + }); + + test("starting with non-letter/non-underscore stays", () => { + return expect(`{ :@foo => "bar" }`).toMatchFormat(); + }); + + test("starting with underscore converts", () => { + return expect(`{ :_foo => "bar" }`).toChangeFormat(`{ _foo: "bar" }`); + }); + }); + + test("prints hashes with consistent keys", () => { + return expect(`{ a: "a", b => "b" }`).toChangeFormat( + `{ :a => "a", b => "b" }` + ); + }); + + test("print hashes with correct braces when contents fits", () => { + const content = ruby(` + { + key1: ${long.slice(0, 32)}, + key2: ${long.slice(0, 32)} + } + `); + + return expect(content).toMatchFormat(); + }); + + test("with leading comments but none in body", () => { + const content = ruby(` + # leading + {} + `); + + return expect(content).toMatchFormat(); + }); + + test("with leading comments and comments in the body", () => { + const content = ruby(` + # leading + { + # inside + # body + } + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments just in the body", () => { + const content = ruby(` + { + # inside + # body + } + `); + + return expect(content).toMatchFormat(); + }); + + // https://github.com/prettier/plugin-ruby/issues/758 + test("splits if the key has a comment attached", () => { + const content = ruby(` + items = { + :"foo-bar"=> # Inline comment + baz, + } + `); + + const expected = ruby(` + items = { + "foo-bar": # Inline comment + baz + } + `); + + return expect(content).toChangeFormat(expected); + }); + + test("child hashes break assoc_news if their parents break", () => { + const content = ruby(` + { + ${long}: { foo: bar } + } + `); + + const expected = ruby(` + { + ${long}: { + foo: bar + } + } + `); + + return expect(content).toChangeFormat(expected); + }); + + test("child hashes break hashes if their parents break", () => { + const key = long.slice(0, 40); + const content = ruby(` + { + ${key}: foo, + ${key}: foo, + ${key}: { foo: bar } + } + `); + + const expected = ruby(` + { + ${key}: foo, + ${key}: foo, + ${key}: { + foo: bar + } + } + `); + + return expect(content).toChangeFormat(expected); + }); +}); diff --git a/test/js/ruby/nodes/heredocs.test.js b/test/js/ruby/nodes/heredocs.test.js new file mode 100644 index 00000000..77e5e8fb --- /dev/null +++ b/test/js/ruby/nodes/heredocs.test.js @@ -0,0 +1,537 @@ +import { long, ruby } from "../../utils.js"; + +describe("heredocs", () => { + describe("straight", () => { + test("basic", () => { + const content = ruby(` + <<-HERE + This is a straight heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with interpolation", () => { + const content = ruby(` + <<-HERE + This is a straight heredoc + #{interpolation} + with interpolation + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on an assignment", () => { + const content = ruby(` + abc = <<-HERE + This is a straight heredoc on an assign + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("nested within another", () => { + const content = ruby(` + <<-PARENT + This is a straight heredoc + #{<<-CHILD} + This is an interpolated straight heredoc + CHILD + PARENT + `); + + return expect(content).toMatchFormat(); + }); + + test("with embedded expressions", () => { + const content = ruby(` + <<-HERE + ${long} + ${long} + #{id} + ${long} + ${long} + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with a call and indented", () => { + const content = ruby(` + def foo + <<-HERE.strip + bar + HERE + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("squiggly heredocs", () => { + test("basic", () => { + const content = ruby(` + <<~HERE + This is a squiggly heredoc + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with interpolation", () => { + const content = ruby(` + <<~HERE + This is a squiggly heredoc + #{interpolation} + with interpolation + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on an assignment", () => { + const content = ruby(` + abc = <<~HERE + This is a squiggly heredoc on an assign + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("nested within another", () => { + const content = ruby(` + <<~PARENT + This is a squiggly heredoc + #{<<~CHILD} + This is an interpolated squiggly heredoc + CHILD + PARENT + `); + + return expect(content).toMatchFormat(); + }); + + test("with a call and indented", () => { + const content = ruby(` + def foo + <<~HERE.strip + bar + HERE + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("as an argument", () => { + test("on calls", () => { + const content = ruby(` + call(1, 2, 3, <<-HERE) + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on calls with multiple", () => { + const content = ruby(` + call(1, 2, 3, <<-HERE, <<-THERE) + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on commands", () => { + const content = ruby(` + command 1, 2, 3, <<-HERE + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on commands with multiple", () => { + const content = ruby(` + command 1, 2, 3, <<-HERE, <<-THERE + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on command calls", () => { + const content = ruby(` + command.call 1, 2, 3, <<-HERE + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on command calls with multiple", () => { + const content = ruby(` + command.call 1, 2, 3, <<-HERE, <<-THERE + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("with a call attached", () => { + test("squiggly no indent", () => { + const content = ruby(` + foo = <<~TEXT.strip + bar + TEXT + `); + + return expect(content).toMatchFormat(); + }); + + test("squiggly indent", () => { + const content = ruby(` + foo = <<~TEXT.strip + bar + TEXT + `); + + return expect(content).toMatchFormat(); + }); + + test("straight no indent", () => { + const content = ruby(` + foo = <<-TEXT.strip + bar + TEXT + `); + + return expect(content).toMatchFormat(); + }); + }); + + test("as args w/ long hash key after heredoc", () => { + const content = ruby(` + foo( + <<~FOO, + foo + FOO + ${long}: + "bar" + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("arg w/ block", () => { + const content = ruby(` + puts(<<~TEXT + Hello + TEXT + ) { "sample block" } + `); + + const expected = ruby(` + puts(<<~TEXT) { "sample block" } + Hello + TEXT + `); + + return expect(content).toChangeFormat(expected); + }); + + test("in an activerecord scope arg w/ chaining", () => { + const content = ruby(` + scope :late_for_checkin, -> { + select( + <<~EOS.squish + some complicated query here + EOS + ) + .data_push + .having("something") + } + `); + + const expected = ruby(` + scope :late_for_checkin, + -> { select(<<~EOS.squish).data_push.having("something") } + some complicated query here + EOS + `); + + return expect(content).toChangeFormat(expected); + }); + + test("long breakable arg after heredoc literal", () => { + const content = ruby(` + p <<-BAR, [${long}] + text + BAR + `); + + const expected = ruby(` + p <<-BAR, + text + BAR + [ + ${long} + ] + `); + + return expect(content).toChangeFormat(expected); + }); + + test("call w/ short breakable arg after heredoc literal", () => { + const content = ruby(` + p(<<-BAR, ["value", "value", 125_484, 0o24024103]) + text + BAR + `); + + return expect(content).toMatchFormat(); + }); + + test("on calls", () => { + const content = ruby(` + call(1, 2, 3, <<-HERE) do + foo + HERE + puts "more code" + end + `); + + const expected = ruby(` + call(1, 2, 3, <<-HERE) { puts "more code" } + foo + HERE + `); + + return expect(content).toChangeFormat(expected); + }); + + test("on calls with trailing arguments", () => { + const content = ruby(` + call(1, <<-HERE, 2) + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("in parens args with trailing args after", () => { + const content = ruby(` + Foo.new(<<-ARG1, "test2") + test1 line 1 + test1 line 2 + ARG1 + `); + + return expect(content).toMatchFormat(); + }); + + test("in paren args with a call", () => { + const content = ruby(` + Foo.new(<<~ARG1.upcase.chomp, "test2") + test1 line 1 + test1 line 2 + ARG1 + `); + + return expect(content).toMatchFormat(); + }); + + test("on calls with multiple", () => { + const content = ruby(` + call(1, 2, 3, <<-HERE, <<-THERE) + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on commands", () => { + const content = ruby(` + command 1, 2, 3, <<-HERE + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on commands with multiple", () => { + const content = ruby(` + command 1, 2, 3, <<-HERE, <<-THERE + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on command calls with trailing arg", () => { + const content = ruby(` + command.call 1, 2, 3, <<-HERE, 4 + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("on command calls with multiple", () => { + const content = ruby(` + command.call 1, 2, 3, <<-HERE, <<-THERE + here + HERE + there + THERE + `); + + return expect(content).toMatchFormat(); + }); + + test("assign with call", () => { + const content = ruby(` + foo = <<~TEXT.strip + bar + TEXT + `); + + return expect(content).toMatchFormat(); + }); + + test("assign with squiggly indent", () => { + const content = ruby(` + foo = (<<~TEXT + bar + TEXT + ).strip + `); + + return expect(content).toChangeFormat( + ruby(` + foo = (<<~TEXT).strip + bar + TEXT + `) + ); + }); + + test("assign with straight no indent", () => { + const content = ruby(` + foo = <<-TEXT.strip + bar + TEXT + `); + + return expect(content).toMatchFormat(); + }); + + test("with a call and indented", () => { + const content = ruby(` + def foo + <<-HERE.strip + bar + HERE + end + `); + + return expect(content).toMatchFormat(); + }); + + test("with a method call", () => { + const content = ruby(` + <<-HERE.strip.chomp + This is a straight heredoc + with two method calls + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with two calls and indented", () => { + const content = ruby(` + def foo + <<~HERE.strip.chomp + bar + HERE + end + `); + + return expect(content).toMatchFormat(); + }); + + test("xstring", () => { + const content = ruby(` + <<-\`SHELL\` + ls + SHELL + `); + + return expect(content).toMatchFormat(); + }); + + test("with a comment after the declaration", () => { + const content = ruby(` + <<~HERE # foo + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("with a comment after the declaration in a call", () => { + const content = ruby(` + list << <<~HERE # foo + foo + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("spilling out from another node keeps subsequent formatting", () => { + const content = ruby(` + foo { <<~BAR.baz } + qux + BAR + qaz + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/hooks.test.js b/test/js/ruby/nodes/hooks.test.js new file mode 100644 index 00000000..a5d94a65 --- /dev/null +++ b/test/js/ruby/nodes/hooks.test.js @@ -0,0 +1,43 @@ +import { long, ruby } from "../../utils.js"; + +describe.each(["BEGIN", "END"])("%s hook", (hook) => { + test("shortens to one line", () => { + return expect(`${hook} {\n p "hook"\n}`).toChangeFormat( + `${hook} { p "hook" }` + ); + }); + + test("maintains single lines", () => { + return expect(`${hook} { p "hook" }`).toMatchFormat(); + }); + + test("maintains multi line", () => { + return expect(`${hook} {\n ${long}\n}`).toMatchFormat(); + }); + + test("expands to multi line", () => { + return expect(`${hook} { ${long} }`).toChangeFormat( + `${hook} {\n ${long}\n}` + ); + }); + + test("does not move comments on the declaration", () => { + const content = ruby(` + ${hook} { # comment + p "hook" + } + `); + + return expect(content).toMatchFormat(); + }); + + test("works for comments in the body", () => { + const content = ruby(` + ${hook} { + # this is the comment + } + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/kwargs.test.js b/test/js/ruby/nodes/kwargs.test.js new file mode 100644 index 00000000..4aa5d4f5 --- /dev/null +++ b/test/js/ruby/nodes/kwargs.test.js @@ -0,0 +1,13 @@ +describe("kwargs", () => { + test("basic", () => { + return expect("def foo(bar: baz)\nend").toMatchFormat(); + }); + + test("optional", () => { + return expect("def foo(bar:)\nend").toMatchFormat(); + }); + + test("double splat", () => { + return expect("def foo(bar:, **baz)\nend").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/lambda.test.js b/test/js/ruby/nodes/lambda.test.js new file mode 100644 index 00000000..a1f9dc3c --- /dev/null +++ b/test/js/ruby/nodes/lambda.test.js @@ -0,0 +1,96 @@ +import { long, ruby } from "../../utils.js"; + +describe("lambda", () => { + test("plain stabby lambda literal", () => { + return expect("-> { 1 }").toMatchFormat(); + }); + + test("stabby lambda literal with args", () => { + return expect("->(a, b, c) { a + b + c }").toMatchFormat(); + }); + + test("stabby lambda literal with arg, no parens", () => { + return expect("-> a { a }").toChangeFormat("->(a) { a }"); + }); + + test("stabby lambda with parens, no args", () => { + return expect("-> () { 1 }").toChangeFormat("-> { 1 }"); + }); + + test("breaking stabby lambda literal", () => { + return expect(`-> { ${long} }`).toChangeFormat(`-> do\n ${long}\nend`); + }); + + test("breaking stabby lambda literal with args", () => { + const content = `->(a) { a + ${long} }`; + const expected = `->(a) do\n a +\n ${long}\nend`; + + return expect(content).toChangeFormat(expected); + }); + + test("stabby lambda literal within a command node", () => { + return expect("command :foo, ->(arg) { arg + arg }").toMatchFormat(); + }); + + test("stabby lambda literal that breaks within a command node", () => { + return expect(`command :foo, -> { ${long} }`).toChangeFormat( + ruby(` + command :foo, + -> do + ${long} + end + `) + ); + }); + + test("stabby lambda literal with a command call node", () => { + return expect("command.call :foo, ->(arg) { arg + arg }").toMatchFormat(); + }); + + test("stabby lambda literal that breaks with a command call node", () => { + return expect(`command.call :foo, -> { ${long} }`).toChangeFormat( + ruby(` + command.call :foo, + -> do + ${long} + end + `) + ); + }); + + test("stabby lambda literal that breaks deeply within a command node", () => { + return expect(`command :foo, bar: -> { ${long} }`).toChangeFormat( + ruby(` + command :foo, + bar: -> do + ${long} + end + `) + ); + }); + + test("very long arguments list doesn't break within pipes", () => { + const content = `command :foo, ->(${long}, a${long}, aa${long}) { true }`; + + return expect(content).toChangeFormat( + ruby(` + command :foo, + ->( + ${long}, + a${long}, + aa${long} + ) do + true + end + `) + ); + }); + + test("empty brackets", () => { + return expect("a[]").toMatchFormat(); + }); + + test("brackets with multiple args", () => { + return expect("a[1, 2, 3]").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/loops.test.js b/test/js/ruby/nodes/loops.test.js new file mode 100644 index 00000000..fb1bc9bc --- /dev/null +++ b/test/js/ruby/nodes/loops.test.js @@ -0,0 +1,160 @@ +import { long, ruby } from "../../utils.js"; + +describe.each(["while", "until"])("%s", (keyword) => { + test("aligns predicates", () => { + return expect(`foo ${keyword} ${long} || ${long}`).toChangeFormat( + ruby(` + ${keyword} ${long} || + ${Array(keyword.length).fill("").join(" ")}${long} + foo + end + `) + ); + }); + + describe("inlines allowed", () => { + test("transforms to inline", () => { + return expect(`${keyword} a\n 1\nend`).toChangeFormat(`1 ${keyword} a`); + }); + + test("maintains inlines", () => { + return expect(`1 ${keyword} a`).toMatchFormat(); + }); + + test("breaks on large predicates", () => { + return expect(`${keyword} ${long}\n 1\nend`).toMatchFormat(); + }); + + test("breaks inlines on large predicates", () => { + return expect(`1 ${keyword} ${long}`).toChangeFormat( + `${keyword} ${long}\n 1\nend` + ); + }); + + test("does not break into block when modifying a begin", () => { + const content = ruby(` + begin + foo + end ${keyword} bar + `); + + return expect(content).toMatchFormat(); + }); + + test("breaks when an assignment is in the predicate", () => { + const content = ruby(` + ${keyword} (a = 1) + a + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaks when a multi assignment is in the predicate", () => { + const content = ruby(` + ${keyword} (a, b = 1, 2) + a + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaks the parent when there is an assignment", () => { + const content = ruby(` + foo do + while foo = foo + yield foo + end + end + `); + + return expect(content).toMatchFormat(); + }); + + test("wraps single lines in parens when assigning", () => { + return expect( + `hash[:key] = ${keyword} false do break :value end` + ).toChangeFormat(`hash[:key] = (break :value ${keyword} false)`); + }); + + test("empty body", () => { + const content = ruby(` + while foo + end + `); + + return expect(content).toMatchFormat(); + }); + + test("empty body, long predicate", () => { + const content = ruby(` + while ${long} + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe.each(["while", "until"])( + "add parens when necessary %s", + (keyword) => { + test("args", () => { + return expect(`[${keyword} foo? do bar end]`).toChangeFormat( + `[(bar ${keyword} foo?)]` + ); + }); + + test("assign", () => { + return expect(`foo = ${keyword} bar? do baz end`).toChangeFormat( + `foo = (baz ${keyword} bar?)` + ); + }); + + test("assoc", () => { + return expect(`{ foo: ${keyword} bar? do baz end }`).toChangeFormat( + `{ foo: (baz ${keyword} bar?) }` + ); + }); + + test("massign", () => { + return expect(`f, o, o = ${keyword} bar? do baz end`).toChangeFormat( + `f, o, o = (baz ${keyword} bar?)` + ); + }); + + test("opassign", () => { + return expect(`foo ||= ${keyword} bar? do baz end`).toChangeFormat( + `foo ||= (baz ${keyword} bar?)` + ); + }); + } + ); + + // https://github.com/prettier/plugin-ruby/issues/759 + test("handles do keyword", () => { + const content = ruby(` + %w[foo bar].each do |resource| + puts resource + + # comment comment + ${keyword} @client.missing?(resource) do + sleep 1 + end + end + `); + + const expected = ruby(` + %w[foo bar].each do |resource| + puts resource + + # comment comment + sleep 1 ${keyword} @client.missing?(resource) + end + `); + + return expect(content).toChangeFormat(expected); + }); +}); diff --git a/test/js/ruby/nodes/massign.test.js b/test/js/ruby/nodes/massign.test.js new file mode 100644 index 00000000..5c0ac339 --- /dev/null +++ b/test/js/ruby/nodes/massign.test.js @@ -0,0 +1,67 @@ +describe("massign", () => { + test("multi on left, multi on right", () => { + return expect("a, b, c = 1, 2, 3").toMatchFormat(); + }); + + test("single on left, multi on right", () => { + return expect("a = 1, 2, 3").toMatchFormat(); + }); + + test("multi on left, array on right", () => { + return expect("a, b, c = [1, 2, 3]").toMatchFormat(); + }); + + test("parens on left, multi on right", () => { + return expect("(a, b, c) = 1, 2, 3").toChangeFormat("a, b, c = 1, 2, 3"); + }); + + test("double parens on left, multi on right", () => { + return expect("((a, b, c)) = 1, 2, 3").toChangeFormat("a, b, c = 1, 2, 3"); + }); + + test("parens on some of left, multi on right", () => { + return expect("(a, b), c = [1, 2], 3").toMatchFormat(); + }); + + test("extra commas at the end", () => { + return expect("a, = 1").toMatchFormat(); + }); + + test("extra commas at the end with multiple", () => { + return expect("a, b, c, = 1").toMatchFormat(); + }); + + test("extra commas with parens", () => { + return expect("(a, b,), c, = 1").toMatchFormat(); + }); + + test("extra commas with doubled parens", () => { + return expect("((a, b,), c,), = 1").toMatchFormat(); + }); + + describe("splat", () => { + test("after ident", () => { + return expect("a, *b = 1, 2, 3").toMatchFormat(); + }); + + test("between idents", () => { + return expect("a, *b, c, d = 1, 2, 3").toMatchFormat(); + }); + + test("with no name", () => { + return expect("a, * = 1, 2, 3").toMatchFormat(); + }); + + test("on right side", () => { + return expect("a = *a").toMatchFormat(); + }); + + test("only on left side", () => { + return expect("* = [1, 2, 3]").toMatchFormat(); + }); + + test("and then ident on left side", () => { + return expect("*, a = [1, 2, 3]").toMatchFormat(); + }); + }); +}); diff --git a/test/js/ruby/nodes/method.test.js b/test/js/ruby/nodes/method.test.js new file mode 100644 index 00000000..5195e29f --- /dev/null +++ b/test/js/ruby/nodes/method.test.js @@ -0,0 +1,394 @@ +import { atLeastVersion, long, ruby } from "../../utils.js"; + +describe("method", () => { + describe("definitions", () => { + test("shorthand for empty methods", () => { + return expect("def foo; end").toChangeFormat("def foo\nend"); + }); + + test("shorthand for empty methods with parens", () => { + return expect("def foo(); end").toChangeFormat("def foo()\nend"); + }); + + test("single arg, no parens", () => { + return expect("def foo bar\nend").toChangeFormat("def foo(bar)\nend"); + }); + + test("single arg, with parens", () => { + return expect("def foo(bar)\nend").toMatchFormat(); + }); + + test("shorthand for empty singleton methods", () => { + return expect("def self.foo; end").toChangeFormat("def self.foo\nend"); + }); + + test("shorthand for empty singleton methods with parens", () => { + return expect("def self.foo(); end").toChangeFormat( + "def self.foo()\nend" + ); + }); + + test("singleton, single arg, no parens", () => { + return expect("def self.foo bar\nend").toChangeFormat( + "def self.foo(bar)\nend" + ); + }); + + test("singleton, single arg, with parens", () => { + return expect("def self.foo(bar)\nend").toMatchFormat(); + }); + + test("shorthand with a body", () => { + return expect("def foo(alpha); 1; end").toChangeFormat( + "def foo(alpha)\n 1\nend" + ); + }); + + test("single splat arg with no name", () => { + return expect("def foo(*); end").toChangeFormat("def foo(*)\nend"); + }); + + test("double splat arg with no name", () => { + return expect("def foo(**); end").toChangeFormat("def foo(**)\nend"); + }); + + test("with helper method", () => { + const content = ruby(` + private def foo + "bar" + end + `); + + return expect(content).toMatchFormat(); + }); + + test("with helper method on defs", () => { + const content = ruby(` + private def self.foo + "bar" + end + `); + + return expect(content).toMatchFormat(); + }); + + test("every single arg type", () => { + const content = ruby(` + def method(req, *rest, post, kwarg:, kwarg_opt: 1, **kwarg_rest, &block) + "foo" + end + `); + + return expect(content).toMatchFormat(); + }); + + test("breaking", () => { + const content = `def foo(${long}:, a${long}:); end`; + const expected = ruby(` + def foo( + ${long}:, + a${long}: + ) + end + `); + + return expect(content).toChangeFormat(expected); + }); + + test("with comments on method definition", () => { + const content = ruby(` + def foo( # bar + ${long}: + ) + ${long} + end + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments on params", () => { + const content = ruby(` + def method( + req, # req comment + *rest, # rest comment + post, # post comment + kwarg:, # kwarg comment + kwarg_opt: 1, # kwarg_opt comment + **kwarg_rest, # kwarg_rest comment + &block # block comment + ) + "foo" + end + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments on optional params", () => { + const content = ruby(` + def method( + optl = "value" # comment + ) + "foo" + end + `); + + return expect(content).toMatchFormat(); + }); + + if (atLeastVersion("2.7")) { + test("nokw_param", () => { + return expect("def foo(**nil); end").toChangeFormat( + "def foo(**nil)\nend" + ); + }); + + test("args_forward", () => { + const content = ruby(` + def foo(...) + bar(...) + end + `); + + return expect(content).toMatchFormat(); + }); + } + + if (atLeastVersion("3.0")) { + test("args_forward with other arguments", () => { + const content = ruby(` + def get(...) + request(:get, ...) + end + `); + + return expect(content).toMatchFormat(); + }); + + test("single-line methods", () => { + return expect("def foo = bar").toMatchFormat(); + }); + + test("single-line methods with params", () => { + return expect("def foo(name) = bar").toMatchFormat(); + }); + } + + test("comments on kwargs", () => { + const content = ruby(` + def foo( + bar:, # hello + baz: + ) + bar + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("method calls", () => { + test("single args", () => { + return expect("foo(1)").toMatchFormat(); + }); + + test("multi arg", () => { + return expect("foo(1, 2)").toMatchFormat(); + }); + + test("just block", () => { + return expect("foo(&block)").toMatchFormat(); + }); + + describe("commands", () => { + test("alignment", () => { + const content = ruby(` + command.call some_method( + ${long} + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("alignment for `to`", () => { + const content = ruby(` + expect(value).to matcher( + ${long} + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("alignment for `not_to`", () => { + const content = ruby(` + expect(value).not_to matcher( + ${long} + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("alignment for `to_not`", () => { + const content = ruby(` + expect(value).to_not matcher( + ${long} + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("just block", () => { + const content = ruby(` + def curry(&block) + new &block + end + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("single splat", () => { + test("plain", () => { + return expect("foo(*bar)").toMatchFormat(); + }); + + test("with multi args", () => { + return expect("foo(1, 2, *abc)").toMatchFormat(); + }); + + test("between multi args", () => { + return expect("foo(1, 2, *abc, 3, 4)").toMatchFormat(); + }); + + test("with comments", () => { + const content = ruby(` + foo( + # comment + # another comment + # even more comment + *values + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("with trailing comments", () => { + const content = ruby(` + foo( + # comment + # another comment + *values # a trailing comment + # a whole other comment + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("with block", () => { + return expect("foo(*bar, &block)").toMatchFormat(); + }); + + test("with comments and block", () => { + const content = ruby(` + foo( + # comment + &block + ) + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("double splat", () => { + test("plain", () => { + return expect("foo(**bar)").toMatchFormat(); + }); + + test("with block", () => { + return expect("foo(**bar, &block)").toMatchFormat(); + }); + + test("with splat and block", () => { + return expect("foo(*bar, **baz, &block)").toMatchFormat(); + }); + + test("after kwarg", () => { + return expect("foo(kwarg: 1, **splat)").toMatchFormat(); + }); + + test("before kwarg", () => { + return expect("foo(**splat, kwarg: 1)").toMatchFormat(); + }); + + test("before kwargs", () => { + return expect("foo(before: 1, **splat, after: 1)").toMatchFormat(); + }); + }); + + describe("different operators", () => { + test("double colon gets changed", () => { + return expect("Foo::foo").toChangeFormat("Foo.foo"); + }); + + test("lonely operator", () => { + return expect("foo&.foo").toMatchFormat(); + }); + }); + + describe("breaking", () => { + describe("without trailing commas", () => { + test("starting with no trailing comma stays", () => { + return expect(`foo(${long}, a${long})`).toChangeFormat( + `foo(\n ${long},\n a${long}\n)` + ); + }); + + test("with breaking ternary as first argument", () => { + return expect(`foo bar ? ${long} : a${long}`).toChangeFormat( + `foo(\n if bar\n ${long}\n else\n a${long}\n end\n)` + ); + }); + + test("starting with trailing comma changes", () => { + return expect(`foo(${long}, a${long},)`).toChangeFormat( + `foo(\n ${long},\n a${long}\n)` + ); + }); + + test("with block on the end", () => { + return expect(`foo(${long}, &block)`).toChangeFormat( + `foo(\n ${long},\n &block\n)` + ); + }); + + test("on commands", () => { + return expect(`command ${long}, a${long}`).toChangeFormat( + ruby(` + command ${long}, + a${long} + `) + ); + }); + + test("on command calls", () => { + return expect(`command.call ${long}, a${long}`).toChangeFormat( + ruby(` + command.call ${long}, + a${long} + `) + ); + }); + }); + }); + }); +}); diff --git a/test/js/ruby/nodes/next.test.js b/test/js/ruby/nodes/next.test.js new file mode 100644 index 00000000..b1a9fb54 --- /dev/null +++ b/test/js/ruby/nodes/next.test.js @@ -0,0 +1,34 @@ +import { ruby } from "../../utils.js"; + +describe("next", () => { + test("bare", () => { + return expect("next").toMatchFormat(); + }); + + test("one arg, no parens", () => { + return expect("next 1").toMatchFormat(); + }); + + test("one arg, with parens", () => { + return expect("next(1)").toChangeFormat("next 1"); + }); + + test("multiple args", () => { + return expect("next 1, 2").toMatchFormat(); + }); + + test("keeps parens for multiple statements", () => { + const expected = ruby(` + next( + a = 1 + a == 1 + ) + `); + + return expect("next(a = 1; a == 1)").toChangeFormat(expected); + }); + + test("keeps parens for _mod nodes", () => { + return expect("next(1 if true)").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/numbers.test.js b/test/js/ruby/nodes/numbers.test.js new file mode 100644 index 00000000..a1edd35b --- /dev/null +++ b/test/js/ruby/nodes/numbers.test.js @@ -0,0 +1,49 @@ +describe("numbers", () => { + test("basic", () => { + return expect("123").toMatchFormat(); + }); + + test("preserves sign", () => { + return expect("-123").toMatchFormat(); + }); + + test("respects no o for octal numbers", () => { + return expect("0123").toChangeFormat("0123"); + }); + + test("respects o for octal numbers", () => { + return expect("0o123").toChangeFormat("0o123"); + }); + + test("does not consider numbers large until they have more than 4 digits", () => { + return expect("1234").toMatchFormat(); + }); + + test("for large numbers adds underscores (mod 3 ==== 0)", () => { + return expect("123456").toChangeFormat("123_456"); + }); + + test("for large numbers adds underscores (mod 3 === 1)", () => { + return expect("1234567").toChangeFormat("1_234_567"); + }); + + test("for large numbers add underscores (mod 3 ==== 2)", () => { + return expect("12345678").toChangeFormat("12_345_678"); + }); + + test("ignores numbers that already have underscores", () => { + return expect("2019_04_17_17_09_00").toMatchFormat(); + }); + + test("ignores formatting on binary numbers", () => { + return expect("0b01101001").toMatchFormat(); + }); + + test("ignores formatting on octal numbers", () => { + return expect("0o123401234").toMatchFormat(); + }); + + test("ignores formatting on hex numbers", () => { + return expect("0x123401234").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/patterns.test.js b/test/js/ruby/nodes/patterns.test.js new file mode 100644 index 00000000..19e0793f --- /dev/null +++ b/test/js/ruby/nodes/patterns.test.js @@ -0,0 +1,189 @@ +import { atLeastVersion, atMostVersion, ruby } from "../../utils.js"; + +describe("patterns", () => { + if (atMostVersion("2.7")) { + test("pattern matching does not exist before ruby 2.7", () => { + // this is here because test files must contain at least one test, so for + // earlier versions of ruby this is just going to chill here + }); + + return; + } + + const cases = [ + "0", + "-1..1", + "Integer", + "bar", + "0 | 1 | 2", + "Integer => bar", + "Object[0, *bar, 1]", + "^bar", + "{ x: 0.. => px, **rest }", + "**rest", + "SuperPoint[x: 0.. => px]" + ]; + + if (atLeastVersion("3.0")) { + cases.push("[*, 0, *]", "[*, 0, 1, 2, *]", "FooBar[*, 0, *]"); + + test("rassign", () => { + const content = `{ db: { user: "John" } } => { db: { user: } }`; + + return expect(content).toMatchFormat(); + }); + + test("rassign with fndptn", () => { + const content = "(1..10).to_a.shuffle => [*bef, 2..4 => thresh, *aft]"; + + return expect(content).toMatchFormat(); + }); + } + + test.each(cases)("%s", (pattern) => { + const content = ruby(` + case foo + in ${pattern} + baz + end + `); + + return expect(content).toMatchFormat(); + }); + + test("a, b, *c, d, e", () => { + const content = ruby(` + case foo + in a, b, *c, d, e + baz + end + `); + + const expectedContent = ruby(` + case foo + in [a, b, *c, d, e] + baz + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("0, [1, _] => bar", () => { + const content = ruby(` + case foo + in 0, [1, _] => bar + baz + end + `); + + const expectedContent = ruby(` + case foo + in [0, [1, _] => bar] + baz + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("*c, d, e", () => { + const content = ruby(` + case foo + in *c, d, e + baz + end + `); + + const expectedContent = ruby(` + case foo + in [*c, d, e] + baz + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("_, _", () => { + const content = ruby(` + case foo + in _, _ + baz + end + `); + + const expectedContent = ruby(` + case foo + in [_, _] + baz + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("a, b if b == a * 2", () => { + const content = ruby(` + case foo + in a, b if b == a * 2 + baz + end + `); + + const expectedContent = ruby(` + case foo + in [a, b] if b == a * 2 + baz + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("with a single array element", () => { + const content = ruby(` + case value + in [element] + matched + end + `); + + return expect(content).toMatchFormat(); + }); + + test("with comments in an array pattern", () => { + const content = ruby(` + case foo + in 1, # 1 comment + 2 # 2 comment + bar + end + `); + + const expectedContent = ruby(` + case foo + in [ + 1, # 1 comment + 2 + ] # 2 comment + bar + end + `); + + return expect(content).toChangeFormat(expectedContent); + }); + + test("multiple clauses", () => { + const content = ruby(` + case foo + in bar + 1 + in baz + 2 + end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/ranges.test.js b/test/js/ruby/nodes/ranges.test.js new file mode 100644 index 00000000..1f92ba36 --- /dev/null +++ b/test/js/ruby/nodes/ranges.test.js @@ -0,0 +1,39 @@ +import { atLeastVersion } from "../../utils.js"; + +describe("ranges", () => { + test("two dot", () => { + return expect("1..2").toMatchFormat(); + }); + + test("negative two dot", () => { + return expect("-2..-1").toMatchFormat(); + }); + + test("three dot", () => { + return expect("3...4").toMatchFormat(); + }); + + test("negative three dot", () => { + return expect("-4...-3").toMatchFormat(); + }); + + if (atLeastVersion("2.6")) { + test("two dot with no ending", () => { + return expect("1..").toMatchFormat(); + }); + + test("three dot with no ending", () => { + return expect("1...").toMatchFormat(); + }); + } + + if (atLeastVersion("2.7")) { + test("two dot with no beginning", () => { + return expect("..2").toMatchFormat(); + }); + + test("three dot with no beginning", () => { + return expect("...2").toMatchFormat(); + }); + } +}); diff --git a/test/js/ruby/nodes/regexp.test.js b/test/js/ruby/nodes/regexp.test.js new file mode 100644 index 00000000..327e6e2b --- /dev/null +++ b/test/js/ruby/nodes/regexp.test.js @@ -0,0 +1,80 @@ +import { ruby } from "../../utils.js"; + +describe("regexp", () => { + test("basic", () => { + return expect("/abc/").toMatchFormat(); + }); + + test("unnecessary braces", () => { + return expect("%r{abc}").toChangeFormat("/abc/"); + }); + + test("unnecessary slashes", () => { + return expect("%r/abc/").toChangeFormat("/abc/"); + }); + + test("unnecessary brackets", () => { + return expect("%r[abc]").toChangeFormat("/abc/"); + }); + + test("unnecessary parens", () => { + return expect("%r(abc)").toChangeFormat("/abc/"); + }); + + test("necessary braces", () => { + return expect("%r{a/b/c}").toMatchFormat(); + }); + + test("interpolation", () => { + return expect("/a#{inter}c/").toMatchFormat(); + }); + + test("modifiers", () => { + return expect("/abc/i").toMatchFormat(); + }); + + test("braces and modifiers", () => { + return expect("%r{a/b/c}mi").toMatchFormat(); + }); + + test("global interpolation", () => { + return expect("/#$&/").toChangeFormat("/#{$&}/"); + }); + + test("do not change if { and / in regexp literal", () => { + return expect("%r(a{b/c)").toMatchFormat(); + }); + + test("do not change if } and / in regexp literal", () => { + return expect("%r[a}b/c]").toMatchFormat(); + }); + + test("parens with }", () => { + return expect("%r(a}bc)").toChangeFormat("/a}bc/"); + }); + + test("comments in regex", () => { + const content = ruby(` + /\\A + [[:digit:]]+ # 1 or more digits before the decimal point + (\\. # Decimal point + [[:digit:]]+ # 1 or more digits after the decimal point + )? # The decimal point and following digits are optional + \\Z/x + `); + + return expect(content).toMatchFormat(); + }); + + test("forces braces if could be ambiguous with space in command", () => { + return expect("foo %r{ bar}").toMatchFormat(); + }); + + test("forces braces if could be ambiguous with equals in command", () => { + return expect("foo %r{= bar}").toMatchFormat(); + }); + + test("do not force braces if space is in parens", () => { + return expect("foo(/ bar/)").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/rescue.test.js b/test/js/ruby/nodes/rescue.test.js new file mode 100644 index 00000000..4a10d7b1 --- /dev/null +++ b/test/js/ruby/nodes/rescue.test.js @@ -0,0 +1,173 @@ +import { ruby } from "../../utils.js"; + +describe("rescue", () => { + test("inline", () => { + const expected = ruby(` + begin + a + rescue StandardError + nil + end + `); + + return expect("a rescue nil").toChangeFormat(expected); + }); + + test("rescue just variable", () => { + const content = ruby(` + begin + a + rescue => e + nil + end + `); + + return expect(content).toMatchFormat(); + }); + + // from ruby spec/ruby/language/rescue_spec.rb + test("splat errors", () => { + const content = ruby(` + def foo + a + rescue A, *B => e + e + end + `); + + return expect(content).toMatchFormat(); + }); + + // https://github.com/prettier/plugin-ruby/pull/1000 + test("errors with scope resolution operator", () => { + const content = ruby(` + def foo + a + rescue ::A + e + end + `); + + return expect(content).toMatchFormat(); + }); + + test.each(["begin", "def foo"])("%s with every clause", (declaration) => { + const error = "BreakingBreakingBreakingBreakingBreakingError"; + const content = ruby(` + ${declaration} + 1 + rescue ArgumentError + retry + rescue NoMethodError => exception + puts exception + redo + rescue SyntaxError, NoMethodError + 2 + rescue One${error}, Two${error}, Three${error} + 3 + rescue + 4 + else + 5 + ensure + 6 + end + `); + + return expect(content).toChangeFormat( + ruby(` + ${declaration} + 1 + rescue ArgumentError + retry + rescue NoMethodError => exception + puts exception + redo + rescue SyntaxError, NoMethodError + 2 + rescue One${error}, + Two${error}, + Three${error} + 3 + rescue StandardError + 4 + else + 5 + ensure + 6 + end + `) + ); + }); + + test("empty rescue body", () => { + const content = ruby(` + begin + 1 + rescue NoMethodError + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment inline", () => { + const content = ruby(` + begin + foo + rescue Foo # foo + bar + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment inline with multiple", () => { + const content = ruby(` + begin + foo + rescue Foo, Bar # foo + bar + end + `); + + return expect(content).toMatchFormat(); + }); + + test("comment inline with splat", () => { + const content = ruby(` + begin + foo + rescue Foo, *Bar # foo + bar + end + `); + + return expect(content).toMatchFormat(); + }); + + test("one error with a comment", () => { + const content = ruby(` + begin + foo + rescue Discourse::InvalidAccess + # keep going + end + `); + + return expect(content).toMatchFormat(); + }); + + test("two errors with a comment", () => { + const content = ruby(` + begin + foo + rescue Discourse::InvalidAccess, UserDestroyer::PostsExistError + # keep going + end + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/return.test.js b/test/js/ruby/nodes/return.test.js new file mode 100644 index 00000000..0121128c --- /dev/null +++ b/test/js/ruby/nodes/return.test.js @@ -0,0 +1,103 @@ +import { long, ruby } from "../../utils.js"; + +describe("return", () => { + test("bare", () => { + return expect("return").toMatchFormat(); + }); + + test("one arg, no parens", () => { + return expect("return 1").toMatchFormat(); + }); + + test("one arg, with parens", () => { + return expect("return(1)").toChangeFormat("return 1"); + }); + + test("multiple args", () => { + return expect("return 1, 2").toMatchFormat(); + }); + + test("return method call", () => { + return expect("return foo :bar").toMatchFormat(); + }); + + test("return with breaking", () => { + return expect(`return ${long}`).toChangeFormat(`return(\n ${long}\n)`); + }); + + test("returning an array", () => { + return expect("return [1, 2, 3]").toChangeFormat("return 1, 2, 3"); + }); + + test("returning an empty array", () => { + return expect("return []").toMatchFormat(); + }); + + test("returning a single element array", () => { + return expect("return [1]").toMatchFormat(); + }); + + test("returning a list that breaks", () => { + return expect(`return ${long}, ${long}`).toChangeFormat( + `return [\n ${long},\n ${long}\n]` + ); + }); + + test("returning an array within parens", () => { + return expect("return([1, 2, 3])").toChangeFormat("return 1, 2, 3"); + }); + + test("returning a long special array", () => { + return expect(`return %w[${long}]`).toChangeFormat( + `return(\n %w[\n ${long}\n ]\n)` + ); + }); + + test("returning two arguments, one that breaks", () => { + return expect(`return foo, ${long}`).toChangeFormat( + `return [\n foo,\n ${long}\n]` + ); + }); + + test("returning two arguments, the first with parentheses", () => { + return expect("return (1), 2").toMatchFormat(); + }); + + test("returning with the or keyword", () => { + return expect("return(a or b)").toMatchFormat(); + }); + + test("returning with the not keyword", () => { + return expect("return(not a)").toMatchFormat(); + }); + + test("comment inside of return parentheses", () => { + const content = ruby(` + return( + # foo + bar + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("returning multiple statements", () => { + const content = ruby(` + return( + foo + bar + ) + `); + + return expect(content).toMatchFormat(); + }); + + test("returning a value with a modifier if", () => { + const content = ruby(` + return :inactive if given_date.before?(first_event_date) + `); + + return expect(content).toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/strings.test.js b/test/js/ruby/nodes/strings.test.js new file mode 100644 index 00000000..3970ad51 --- /dev/null +++ b/test/js/ruby/nodes/strings.test.js @@ -0,0 +1,269 @@ +import { long, ruby } from "../../utils.js"; + +describe("strings", () => { + describe("%-literals with escape sequences in the middle", () => { + const cases = [ + ["(", ")"], + ["[", "]"], + ["{", "}"], + ["<", ">"], + ["|", "|"] + ]; + + test.each(cases)("%%%s%s", (stringStart, stringEnd) => + expect(`%${stringStart}a\\bc${stringEnd}`).toMatchFormat() + ); + + test.each(cases)("%q%s%s", (stringStart, stringEnd) => + expect(`%q${stringStart}a\\bc${stringEnd}`).toMatchFormat() + ); + + test.each(cases)("%Q%s%s", (stringStart, stringEnd) => + expect(`%Q${stringStart}a\\bc${stringEnd}`).toMatchFormat() + ); + }); + + describe("with single quotes", () => { + test("empty single quote strings stay", () => { + return expect("''").toChangeFormat(`""`); + }); + + test("empty double quote strings change", () => { + return expect(`""`).toMatchFormat(); + }); + + test("basic strings with single quotes stay", () => { + return expect("'abc'").toChangeFormat(`"abc"`); + }); + + test("basic strings with double quotes change", () => { + return expect(`"abc"`).toMatchFormat(); + }); + + test("double quotes with inner single quotes stay", () => { + return expect(`"abc's"`).toMatchFormat(); + }); + + describe("escape sequences", () => { + test("single quotes stay", () => { + return expect("'abc\\n'").toMatchFormat(); + }); + + test("double quotes stay", () => { + return expect(`"abc\\n"`).toMatchFormat(); + }); + + test("interpolation within single quotes stay", () => { + return expect(`'#{"\\n"}'`).toMatchFormat(); + }); + + test("interpolation within double quotes stay", () => { + return expect(`"#{"\\n"}"`).toMatchFormat(); + }); + + test("escaped double quotes are not unquoted", () => { + return expect("'abc \\\"def\\\" ghi'").toMatchFormat(); + }); + }); + }); + + describe("with double quotes", () => { + test("empty single quote strings change", () => { + return expect("''").toChangeFormat(`""`); + }); + + test("empty double quote strings stay", () => { + return expect(`""`).toMatchFormat(); + }); + + test("basic strings with single quotes change", () => { + return expect("'abc'").toChangeFormat(`"abc"`); + }); + + test("basic strings with double quotes stay", () => { + return expect(`"abc"`).toMatchFormat(); + }); + + test("double quotes with inner single quotes stay", () => { + return expect(`"abc's"`).toMatchFormat(); + }); + + test("double quotes do not get escaped if it results in more quotes", () => { + return expect(`'"foo"'`).toMatchFormat(); + }); + + describe("escape sequences", () => { + test("single quotes stay", () => { + return expect("'abc\\n'").toMatchFormat(); + }); + + test("double quotes stay", () => { + return expect(`"abc\\n"`).toMatchFormat(); + }); + + test("interpolation within single quotes stay", () => { + return expect(`'#{"\\n"}'`).toMatchFormat(); + }); + + test("interpolation within double quotes stay", () => { + return expect(`"#{"\\n"}"`).toMatchFormat(); + }); + }); + }); + + describe("with %{} quotes", () => { + test("matches correctly", () => { + return expect("%{foo\\n#{bar}\\nbaz}").toMatchFormat(); + }); + }); + + test("concatenation", () => { + return expect(`"abc" \\\n "def" \\\n "ghi"`).toMatchFormat(); + }); + + describe("interpolation", () => { + test("with keywords", () => { + return expect(`"abc #{super} abc"`).toMatchFormat(); + }); + + test("at the beginning of the string", () => { + return expect(`"#{abc} abc"`).toMatchFormat(); + }); + + test("very interpolated", () => { + return expect(`"abc #{"abc #{abc} abc"} abc"`).toMatchFormat(); + }); + + test("long strings with interpolation do not break", () => { + return expect(`"${long} #{foo[:bar]} ${long}"`).toMatchFormat(); + }); + + test("long strings with interpolation that were broken do break", () => { + const content = ruby(` + <<~HERE + #{ + ${long} + } + HERE + `); + + return expect(content).toMatchFormat(); + }); + + test("within a heredoc there is no indentation", () => { + const content = ruby(` + <<~HERE + #{${long}} + HERE + `); + + return expect(content).toMatchFormat(); + }); + }); + + describe("char literals", () => { + test("single chars get changed", () => { + return expect("?a").toChangeFormat(`"a"`); + }); + + test("single chars get changed with double quotes", () => { + return expect("?a").toChangeFormat(`"a"`); + }); + + test("control escape sequences stay", () => { + return expect("?\\C-a").toMatchFormat(); + }); + + test("meta escape sequences stay", () => { + return expect("?\\M-a").toMatchFormat(); + }); + + test("meta and control sequences stay", () => { + return expect("?\\M-\\C-a").toMatchFormat(); + }); + }); + + describe("xstrings", () => { + test("backtick literals", () => { + return expect("`abc`").toMatchFormat(); + }); + + test("breaking backtick literals", () => { + return expect(`\`${long}\``).toMatchFormat(); + }); + + test("breaking backtick literals with method chains", () => { + return expect(`\`${long}\`.to_s`).toMatchFormat(); + }); + + test("%x literals", () => { + return expect("%x[abc]").toChangeFormat("`abc`"); + }); + + test("breaking %x literals", () => { + return expect(`%x[${long}]`).toChangeFormat(`\`${long}\``); + }); + + test("breaking %x literals with method chains", () => { + return expect(`%x[${long}].to_s`).toChangeFormat(`\`${long}\`.to_s`); + }); + }); + + describe("symbols", () => { + test("basic", () => { + return expect(":abc").toMatchFormat(); + }); + + test("with single quotes", () => { + return expect(":'abc'").toChangeFormat(`:"abc"`); + }); + + test("with double quotes", () => { + return expect(`:"abc"`).toMatchFormat(); + }); + + test("with double quotes with double quotes desired", () => { + return expect(`:"abc"`).toMatchFormat(); + }); + + test("with real interpolation and double quotes", () => { + return expect(`:"abc#{foo}abc"`).toMatchFormat(); + }); + + test("%s literal", () => { + return expect("%s[abc]").toChangeFormat(`:"abc"`); + }); + + test("%s literal with false interpolation", () => { + return expect("%s[abc#{d}]").toChangeFormat(`:'abc#{d}'`); + }); + + test("%s literal as hash key", () => { + return expect("{ %s[abc] => d }").toChangeFormat(`{ abc: d }`); + }); + + test("symbol literal as a hash key", () => { + return expect("{ '\\d' => 1 }").toMatchFormat(); + }); + + test("%s literal with newlines", () => { + const content = ruby(` + a = %s[ + a + ] + `); + + return expect(content).toMatchFormat(); + }); + + test("gets correct quotes", () => { + const content = `where("lint_tool_configs.plugin": plugins + %w[core])`; + + return expect(content).toMatchFormat(); + }); + }); + + test.each(["@v", "@@v", "$v"])("%s dvar", (interp) => { + return expect(`"#${interp}"`).toChangeFormat(`"#{${interp}}"`); + }); +}); diff --git a/test/js/ruby/nodes/super.test.js b/test/js/ruby/nodes/super.test.js new file mode 100644 index 00000000..1b66b025 --- /dev/null +++ b/test/js/ruby/nodes/super.test.js @@ -0,0 +1,73 @@ +import { ruby } from "../../utils.js"; + +describe("super", () => { + test("bare", () => { + return expect("super").toMatchFormat(); + }); + + test("empty parens", () => { + return expect("super()").toMatchFormat(); + }); + + test("one arg, no parens", () => { + return expect("super 1").toMatchFormat(); + }); + + test("one arg, with parens", () => { + return expect("super(1)").toMatchFormat(); + }); + + test("multiple args, no parens", () => { + return expect("super 1, 2").toMatchFormat(); + }); + + test("multiple args, with parens", () => { + return expect("super(1, 2)").toMatchFormat(); + }); + + describe("with comments", () => { + test("bare", () => { + return expect("super # comment").toMatchFormat(); + }); + + test("empty parens", () => { + return expect("super() # comment").toMatchFormat(); + }); + + test("one arg, no parens", () => { + return expect("super 1 # comment").toMatchFormat(); + }); + + test("one arg, with parens", () => { + return expect("super(1) # comment").toMatchFormat(); + }); + + test("multiple args, no parens", () => { + return expect("super 1, 2 # comment").toMatchFormat(); + }); + + test("multiple args, multiple lines, no parens", () => { + const content = ruby(` + super 1, # first comment + 2 # second comment + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple args, with parens", () => { + return expect("super(1, 2) # comment").toMatchFormat(); + }); + + test("multiple args, multiple lines, no parens", () => { + const content = ruby(` + super( + 1, # first comment + 2 # second comment + ) + `); + + return expect(content).toMatchFormat(); + }); + }); +}); diff --git a/test/js/ruby/nodes/unary.test.js b/test/js/ruby/nodes/unary.test.js new file mode 100644 index 00000000..8f619b74 --- /dev/null +++ b/test/js/ruby/nodes/unary.test.js @@ -0,0 +1,10 @@ +describe("unary", () => { + test("regular", () => { + return expect("!foo").toMatchFormat(); + }); + + // https://github.com/prettier/plugin-ruby/issues/764 + test("with other operator", () => { + return expect("!(x&.>(0))").toMatchFormat(); + }); +}); diff --git a/test/js/ruby/nodes/undef.test.js b/test/js/ruby/nodes/undef.test.js new file mode 100644 index 00000000..3716cab6 --- /dev/null +++ b/test/js/ruby/nodes/undef.test.js @@ -0,0 +1,55 @@ +import { long, ruby } from "../../utils.js"; + +describe("undef", () => { + test("single inline", () => { + return expect("undef foo").toMatchFormat(); + }); + + test("multiple inline", () => { + return expect("undef foo, bar").toMatchFormat(); + }); + + test("multiple breaking", () => { + const expected = ruby(` + undef ${long}, + a${long} + `); + + return expect(`undef ${long}, a${long}`).toChangeFormat(expected); + }); + + test("single with comment", () => { + return expect("undef foo # bar").toMatchFormat(); + }); + + test("multiple inline with comment", () => { + return expect("undef foo, bar # baz").toMatchFormat(); + }); + + test("multiple lines comment on first", () => { + const content = ruby(` + undef foo, # baz + bar + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple lines comment on each", () => { + const content = ruby(` + undef foo, # baz + bar # bam + `); + + return expect(content).toMatchFormat(); + }); + + test("multiple breaking with comment", () => { + const expected = ruby(` + undef ${long}, + a${long} # foo + `); + + return expect(`undef ${long}, a${long} # foo`).toChangeFormat(expected); + }); +}); diff --git a/test/js/ruby/nodes/yield.test.js b/test/js/ruby/nodes/yield.test.js new file mode 100644 index 00000000..5ac27496 --- /dev/null +++ b/test/js/ruby/nodes/yield.test.js @@ -0,0 +1,21 @@ +describe("yield", () => { + test("bare yield", () => { + return expect("yield").toMatchFormat(); + }); + + test("yield with one argument, no parens", () => { + return expect("yield i").toMatchFormat(); + }); + + test("yield with one argument, with parens", () => { + return expect("yield(i)").toMatchFormat(); + }); + + test("yield with multiple arguments, no parens", () => { + return expect("yield i, 2").toMatchFormat(); + }); + + test("yield with multiple arguments, with parens", () => { + return expect("yield(i, 2)").toMatchFormat(); + }); +}); diff --git a/test/js/setupTests.js b/test/js/setupTests.js new file mode 100644 index 00000000..c0459fb0 --- /dev/null +++ b/test/js/setupTests.js @@ -0,0 +1,32 @@ +import { format } from "prettier"; +import plugin from "../../src/plugin.js"; + +function normalize(code) { + const string = typeof code === "string" ? code : code.code; + return string.replace(/\r?\n/g, "\n").trim(); +} + +async function checkFormat(before, after) { + const originalText = typeof before === "string" ? before : before.code; + const formatted = await format(originalText, { + parser: typeof before === "string" ? "ruby" : before.parser, + plugins: [plugin] + }); + + const expected = normalize(after); + const received = normalize(formatted); + + return { + pass: received === expected, + message: () => `Expected:\n${expected}\nReceived:\n${received}` + }; +} + +expect.extend({ + toChangeFormat(before, after) { + return checkFormat(before, after); + }, + toMatchFormat(before) { + return checkFormat(before, before); + } +}); diff --git a/test/js/utils.js b/test/js/utils.js new file mode 100644 index 00000000..8ca50d04 --- /dev/null +++ b/test/js/utils.js @@ -0,0 +1,39 @@ +export const long = Array(80).fill("a").join(""); + +function stripLeadingWhitespace(code) { + if (!code.includes("\n")) { + return code; + } + + const lines = code.split("\n"); + + const indent = lines[1].split("").findIndex((char) => /[^\s]/.test(char)); + const content = lines.slice(1, lines.length - 1); + + return content.map((line) => line.slice(indent)).join("\n"); +} + +export function ruby(code) { + return stripLeadingWhitespace(code); +} + +export function rbs(code) { + return { code: stripLeadingWhitespace(code), parser: "rbs" }; +} + +export function haml(code) { + return { code: stripLeadingWhitespace(code), parser: "haml" }; +} + +// The follow are two functions used for comparing against the provided +// RUBY_VERSION environment variable. That variable is set in globalSetup so it +// should be always available. TypeScript doesn't know that though, so we +// explicitly allow it to be undefined by coalescing with the empty string. + +export function atLeastVersion(version) { + return (process.env.RUBY_VERSION || "") >= version; +} + +export function atMostVersion(version) { + return (process.env.RUBY_VERSION || "") < version; +} diff --git a/test/nodes.test.js b/test/nodes.test.js deleted file mode 100644 index 7e837aca..00000000 --- a/test/nodes.test.js +++ /dev/null @@ -1,56 +0,0 @@ -const { spawnSync } = require("child_process"); -const nodes = require("../src/nodes"); - -const expectedUnhandledNodes = [ - "arg_ambiguous", - "args_add", - "args_new", - "heredoc_dedent", - "magic_comment", - "mlhs_add", - "mlhs_new", - "mrhs_add", - "mrhs_new", - "operator_ambiguous", - "parse_error", - "qsymbols_add", - "qsymbols_new", - "qwords_add", - "qwords_new", - "regexp_add", - "regexp_new", - "stmts_add", - "stmts_new", - "string_add", - "string_content", - "symbols_add", - "symbols_new", - "void_stmt", - "words_add", - "words_new", - "xstring_add", - "xstring_new", - "" -]; - -const possibleNodes = () => { - const child = spawnSync("ruby", [ - "-rripper", - "-e", - "puts Ripper::PARSER_EVENTS" - ]); - - const error = child.stderr.toString(); - if (error) { - throw new Error(error); - } - - return child.stdout.toString().split("\n"); -}; - -describe("node support", () => { - test("handles all ripper parsing events", () => { - const supportedNodes = Object.keys(nodes).concat(expectedUnhandledNodes).sort(); - expect(supportedNodes).toEqual(expect.arrayContaining(possibleNodes().sort())); - }); -}); diff --git a/test/print.test.js b/test/print.test.js deleted file mode 100644 index 65e85cfa..00000000 --- a/test/print.test.js +++ /dev/null @@ -1,7 +0,0 @@ -const print = require("../src/print"); - -test("when encountering an unsupported node type", () => { - const path = { getValue: () => ({ type: "unsupported", body: {} }) }; - - expect(() => print(path)).toThrow("Unsupported"); -}); diff --git a/test/rake/task_test.rb b/test/rake/task_test.rb deleted file mode 100644 index af050cd7..00000000 --- a/test/rake/task_test.rb +++ /dev/null @@ -1,26 +0,0 @@ -# frozen_string_literal: true - -require 'test_helper' -require 'prettier/rake/task' - -class TaskTest < Minitest::Test - Invoke = Struct.new(:args) - - def test_task - source_files = '{app,config,lib}/**/*.rb' - Prettier::Rake::Task.new do |t| - t.name = :format - t.write = true - t.source_files = source_files - end - - invoke = nil - $?.stub(:exited?, false) do - Prettier.stub(:run, ->(args) { invoke = Invoke.new(args) }) do - Rake::Task['format'].invoke - end - end - - assert_equal ['--write', source_files], invoke.args - end -end diff --git a/test/rb/rake_test.rb b/test/rb/rake_test.rb new file mode 100644 index 00000000..65891544 --- /dev/null +++ b/test/rb/rake_test.rb @@ -0,0 +1,24 @@ +# frozen_string_literal: true + +require "test_helper" +require "prettier/rake/task" + +class RakeTest < Minitest::Test + Invoke = Struct.new(:args) + + def test_task + source_files = "{app,config,lib}/**/*.rb" + Prettier::Rake::Task.new do |t| + t.name = :format + t.write = true + t.source_files = source_files + end + + invoke = nil + Prettier.stub(:run, ->(args) { invoke = Invoke.new(args) }) do + Rake::Task["format"].invoke + end + + assert_equal ["--write", source_files], invoke.args + end +end diff --git a/test/rb/test_helper.rb b/test/rb/test_helper.rb new file mode 100644 index 00000000..f223f7f0 --- /dev/null +++ b/test/rb/test_helper.rb @@ -0,0 +1,6 @@ +# frozen_string_literal: true + +$LOAD_PATH.unshift(File.expand_path("../../lib", __dir__)) + +require "prettier" +require "minitest/autorun" diff --git a/test/prettier_test.rb b/test/rb/version_test.rb similarity index 62% rename from test/prettier_test.rb rename to test/rb/version_test.rb index a9924700..289590be 100644 --- a/test/prettier_test.rb +++ b/test/rb/version_test.rb @@ -1,8 +1,8 @@ # frozen_string_literal: true -require 'test_helper' +require "test_helper" -class PrettierTest < Minitest::Test +class VersionTest < Minitest::Test def test_version refute_nil ::Prettier::VERSION end diff --git a/test/testRunner.js b/test/testRunner.js deleted file mode 100644 index 85bc7b14..00000000 --- a/test/testRunner.js +++ /dev/null @@ -1,66 +0,0 @@ -const { spawn } = require("child_process"); -const fs = require("fs"); -const path = require("path"); -const prettier = require("prettier"); - -const minitestFiles = [ - "alias.rb", - "array.rb", - "assign.rb", - "binary.rb", - "next.rb", - "numbers.rb", - "kwargs.rb", - "regexp.rb" -]; - -const asyncProcess = child => new Promise((resolve, reject) => ( - child.on("exit", code => { - if (code === 0) { - resolve(); - } else { - reject((child.stdout.read() || child.stderr.read() || "").toString()); - } - }) -)); - -global.runCase = (filename, prettierConfig = {}, rubocopConfig = "default.yml") => { - const file = path.join(__dirname, "cases", filename); - const contents = prettier.format( - fs.readFileSync(file, "utf8"), - Object.assign({}, { parser: "ruby", plugins: ["."] }, prettierConfig) - ); - - describe(filename, () => { - test("matches expected output", () => { - expect(contents).toMatchSnapshot(); - }); - - if (!process.env.NOLINT) { - test("generated code passes rubocop", () => { - const child = spawn("bundle", [ - "exec", "rubocop", "--stdin", file, "--config", `test/config/${rubocopConfig}` - ]); - - child.stdin.write(contents); - child.stdin.end(); - - return asyncProcess(child); - }); - } - - if (minitestFiles.includes(filename)) { - test("generated code passes as a ruby test", () => { - const filepath = `${file.slice(0, -3)}.fmt.rb`; - fs.writeFileSync(filepath, contents); - - const child = spawn("bundle", ["exec", "ruby", "test/test_runner.rb", filepath]); - const ensure = () => fs.unlinkSync(filepath); - - return asyncProcess(child).then(ensure).catch(ensure); - }); - } else { - test.todo("generated code passes as a ruby test"); - } - }); -}; diff --git a/test/test_helper.rb b/test/test_helper.rb deleted file mode 100644 index 4fd14ff9..00000000 --- a/test/test_helper.rb +++ /dev/null @@ -1,6 +0,0 @@ -# frozen_string_literal: true - -$LOAD_PATH.unshift(File.expand_path('../lib', __dir__)) - -require 'prettier' -require 'minitest/autorun' diff --git a/test/test_runner.rb b/test/test_runner.rb deleted file mode 100644 index db37a22b..00000000 --- a/test/test_runner.rb +++ /dev/null @@ -1,5 +0,0 @@ -# frozen_string_literal: true - -require 'bundler/setup' -require 'minitest/autorun' -require ARGV[0] diff --git a/yarn.lock b/yarn.lock index e727510a..dd883b5b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,460 +2,810 @@ # yarn lockfile v1 -"@babel/code-frame@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.0.0.tgz#06e2ab19bdb535385559aabb5ba59729482800f8" - integrity sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA== +"@aashutoshrathi/word-wrap@^1.2.3": + version "1.2.6" + resolved "https://registry.yarnpkg.com/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz#bd9154aec9983f77b3a034ecaa015c2e4201f6cf" + integrity sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA== + +"@ampproject/remapping@^2.2.0": + version "2.2.1" + resolved "https://registry.yarnpkg.com/@ampproject/remapping/-/remapping-2.2.1.tgz#99e8e11851128b8702cd57c33684f1d0f260b630" + integrity sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg== dependencies: - "@babel/highlight" "^7.0.0" + "@jridgewell/gen-mapping" "^0.3.0" + "@jridgewell/trace-mapping" "^0.3.9" -"@babel/core@^7.1.0": - version "7.2.2" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.2.2.tgz#07adba6dde27bb5ad8d8672f15fde3e08184a687" - integrity sha512-59vB0RWt09cAct5EIe58+NzGP4TFSD3Bz//2/ELy3ZeTeKF6VTD1AXlH8BGGbCX0PuobZBsIzO7IAI9PH67eKw== +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.12.13", "@babel/code-frame@^7.22.13", "@babel/code-frame@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.23.4.tgz#03ae5af150be94392cb5c7ccd97db5a19a5da6aa" + integrity sha512-r1IONyb6Ia+jYR2vvIDhdWdlTGhqbBoFqLTQidzZ4kepUFH15ejXvFHxCVbtl7BOXIudsIubf4E81xeA3h3IXA== dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/generator" "^7.2.2" - "@babel/helpers" "^7.2.0" - "@babel/parser" "^7.2.2" - "@babel/template" "^7.2.2" - "@babel/traverse" "^7.2.2" - "@babel/types" "^7.2.2" - convert-source-map "^1.1.0" + "@babel/highlight" "^7.23.4" + chalk "^2.4.2" + +"@babel/compat-data@^7.22.9": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.23.3.tgz#3febd552541e62b5e883a25eb3effd7c7379db11" + integrity sha512-BmR4bWbDIoFJmJ9z2cZ8Gmm2MXgEDgjdWgpKmKWUt54UGFJdlj31ECtbaDvCG/qVdG3AQ1SfpZEs01lUFbzLOQ== + +"@babel/core@^7.11.6", "@babel/core@^7.12.3": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.23.3.tgz#5ec09c8803b91f51cc887dedc2654a35852849c9" + integrity sha512-Jg+msLuNuCJDyBvFv5+OKOUjWMZgd85bKjbICd3zWrKAo+bJ49HJufi7CQE0q0uR8NGyO6xkCACScNqyjHSZew== + dependencies: + "@ampproject/remapping" "^2.2.0" + "@babel/code-frame" "^7.22.13" + "@babel/generator" "^7.23.3" + "@babel/helper-compilation-targets" "^7.22.15" + "@babel/helper-module-transforms" "^7.23.3" + "@babel/helpers" "^7.23.2" + "@babel/parser" "^7.23.3" + "@babel/template" "^7.22.15" + "@babel/traverse" "^7.23.3" + "@babel/types" "^7.23.3" + convert-source-map "^2.0.0" debug "^4.1.0" - json5 "^2.1.0" - lodash "^4.17.10" - resolve "^1.3.2" - semver "^5.4.1" - source-map "^0.5.0" - -"@babel/generator@^7.0.0", "@babel/generator@^7.2.2": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.3.0.tgz#f663838cd7b542366de3aa608a657b8ccb2a99eb" - integrity sha512-dZTwMvTgWfhmibq4V9X+LMf6Bgl7zAodRn9PvcPdhlzFMbvUutx74dbEv7Atz3ToeEpevYEJtAwfxq/bDCzHWg== - dependencies: - "@babel/types" "^7.3.0" + gensync "^1.0.0-beta.2" + json5 "^2.2.3" + semver "^6.3.1" + +"@babel/generator@^7.23.3", "@babel/generator@^7.23.4", "@babel/generator@^7.7.2": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.23.4.tgz#4a41377d8566ec18f807f42962a7f3551de83d1c" + integrity sha512-esuS49Cga3HcThFNebGhlgsrVLkvhqvYDTzgjfFFlHJcIfLe5jFmRRfCQ1KuBfc4Jrtn3ndLgKWAKjBE+IraYQ== + dependencies: + "@babel/types" "^7.23.4" + "@jridgewell/gen-mapping" "^0.3.2" + "@jridgewell/trace-mapping" "^0.3.17" jsesc "^2.5.1" - lodash "^4.17.10" - source-map "^0.5.0" - trim-right "^1.0.1" -"@babel/helper-function-name@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz#a0ceb01685f73355d4360c1247f582bfafc8ff53" - integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== +"@babel/helper-compilation-targets@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.15.tgz#0698fc44551a26cf29f18d4662d5bf545a6cfc52" + integrity sha512-y6EEzULok0Qvz8yyLkCvVX+02ic+By2UdOhylwUOvOn9dvYc9mKICJuuU1n1XBI02YWsNsnrY1kc6DVbjcXbtw== + dependencies: + "@babel/compat-data" "^7.22.9" + "@babel/helper-validator-option" "^7.22.15" + browserslist "^4.21.9" + lru-cache "^5.1.1" + semver "^6.3.1" + +"@babel/helper-environment-visitor@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.20.tgz#96159db61d34a29dba454c959f5ae4a649ba9167" + integrity sha512-zfedSIzFhat/gFhWfHtgWvlec0nqB9YEIVrpuwjruLlXfUSnA8cJB0miHKwqDnQ7d32aKo2xt88/xZptwxbfhA== + +"@babel/helper-function-name@^7.23.0": + version "7.23.0" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.23.0.tgz#1f9a3cdbd5b2698a670c30d2735f9af95ed52759" + integrity sha512-OErEqsrxjZTJciZ4Oo+eoZqeW9UIiOcuYKRJA4ZAgV9myA+pOXhhmpfNCKjEH/auVfEYVFJ6y1Tc4r0eIApqiw== + dependencies: + "@babel/template" "^7.22.15" + "@babel/types" "^7.23.0" + +"@babel/helper-hoist-variables@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz#c01a007dac05c085914e8fb652b339db50d823bb" + integrity sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-module-imports@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.22.15.tgz#16146307acdc40cc00c3b2c647713076464bdbf0" + integrity sha512-0pYVBnDKZO2fnSPCrgM/6WMc7eS20Fbok+0r88fp+YtWVLZrp4CkafFGIp+W0VKw4a22sgebPT99y+FDNMdP4w== + dependencies: + "@babel/types" "^7.22.15" + +"@babel/helper-module-transforms@^7.23.3": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.23.3.tgz#d7d12c3c5d30af5b3c0fcab2a6d5217773e2d0f1" + integrity sha512-7bBs4ED9OmswdfDzpz4MpWgSrV7FXlc3zIagvLFjS5H+Mk7Snr21vQ6QwrsoCGMfNC4e4LQPdoULEt4ykz0SRQ== + dependencies: + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-module-imports" "^7.22.15" + "@babel/helper-simple-access" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/helper-validator-identifier" "^7.22.20" + +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.10.4", "@babel/helper-plugin-utils@^7.12.13", "@babel/helper-plugin-utils@^7.14.5", "@babel/helper-plugin-utils@^7.22.5", "@babel/helper-plugin-utils@^7.8.0": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.22.5.tgz#dd7ee3735e8a313b9f7b05a773d892e88e6d7295" + integrity sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg== + +"@babel/helper-simple-access@^7.22.5": + version "7.22.5" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.22.5.tgz#4938357dc7d782b80ed6dbb03a0fba3d22b1d5de" + integrity sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-split-export-declaration@^7.22.6": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz#322c61b7310c0997fe4c323955667f18fcefb91c" + integrity sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g== + dependencies: + "@babel/types" "^7.22.5" + +"@babel/helper-string-parser@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz#9478c707febcbbe1ddb38a3d91a2e054ae622d83" + integrity sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ== + +"@babel/helper-validator-identifier@^7.22.20": + version "7.22.20" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.20.tgz#c4ae002c61d2879e724581d96665583dbc1dc0e0" + integrity sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A== + +"@babel/helper-validator-option@^7.22.15": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.22.15.tgz#694c30dfa1d09a6534cdfcafbe56789d36aba040" + integrity sha512-bMn7RmyFjY/mdECUbgn9eoSY4vqvacUnS9i9vGAGttgFWesO6B4CYWA7XlpbWgBt71iv/hfbPlynohStqnu5hA== + +"@babel/helpers@^7.23.2": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.23.4.tgz#7d2cfb969aa43222032193accd7329851facf3c1" + integrity sha512-HfcMizYz10cr3h29VqyfGL6ZWIjTwWfvYBMsBVGwpcbhNGe3wQ1ZXZRPzZoAHhd9OqHadHqjQ89iVKINXnbzuw== + dependencies: + "@babel/template" "^7.22.15" + "@babel/traverse" "^7.23.4" + "@babel/types" "^7.23.4" + +"@babel/highlight@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.23.4.tgz#edaadf4d8232e1a961432db785091207ead0621b" + integrity sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A== + dependencies: + "@babel/helper-validator-identifier" "^7.22.20" + chalk "^2.4.2" + js-tokens "^4.0.0" + +"@babel/parser@^7.1.0", "@babel/parser@^7.14.7", "@babel/parser@^7.20.7", "@babel/parser@^7.22.15", "@babel/parser@^7.23.3", "@babel/parser@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.23.4.tgz#409fbe690c333bb70187e2de4021e1e47a026661" + integrity sha512-vf3Xna6UEprW+7t6EtOmFpHNAuxw3xqPZghy+brsnusscJRW5BMUzzHZc5ICjULee81WeUV2jjakG09MDglJXQ== + +"@babel/plugin-syntax-async-generators@^7.8.4": + version "7.8.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" + integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== dependencies: - "@babel/helper-get-function-arity" "^7.0.0" - "@babel/template" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/helper-get-function-arity@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" - integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== +"@babel/plugin-syntax-bigint@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-bigint/-/plugin-syntax-bigint-7.8.3.tgz#4c9a6f669f5d0cdf1b90a1671e9a146be5300cea" + integrity sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg== dependencies: - "@babel/types" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/helper-plugin-utils@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" - integrity sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA== +"@babel/plugin-syntax-class-properties@^7.8.3": + version "7.12.13" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-class-properties/-/plugin-syntax-class-properties-7.12.13.tgz#b5c987274c4a3a82b89714796931a6b53544ae10" + integrity sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA== + dependencies: + "@babel/helper-plugin-utils" "^7.12.13" -"@babel/helper-split-export-declaration@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.0.0.tgz#3aae285c0311c2ab095d997b8c9a94cad547d813" - integrity sha512-MXkOJqva62dfC0w85mEf/LucPPS/1+04nmmRMPEBUB++hiiThQ2zPtX/mEWQ3mtzCEjIJvPY8nuwxXtQeQwUag== +"@babel/plugin-syntax-import-meta@^7.8.3": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-import-meta/-/plugin-syntax-import-meta-7.10.4.tgz#ee601348c370fa334d2207be158777496521fd51" + integrity sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g== dependencies: - "@babel/types" "^7.0.0" + "@babel/helper-plugin-utils" "^7.10.4" -"@babel/helpers@^7.2.0": - version "7.3.1" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.3.1.tgz#949eec9ea4b45d3210feb7dc1c22db664c9e44b9" - integrity sha512-Q82R3jKsVpUV99mgX50gOPCWwco9Ec5Iln/8Vyu4osNIOQgSrd9RFrQeUvmvddFNoLwMyOUWU+5ckioEKpDoGA== +"@babel/plugin-syntax-json-strings@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" + integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== dependencies: - "@babel/template" "^7.1.2" - "@babel/traverse" "^7.1.5" - "@babel/types" "^7.3.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/highlight@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.0.0.tgz#f710c38c8d458e6dd9a201afb637fcb781ce99e4" - integrity sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw== +"@babel/plugin-syntax-jsx@^7.7.2": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.23.3.tgz#8f2e4f8a9b5f9aa16067e142c1ac9cd9f810f473" + integrity sha512-EB2MELswq55OHUoRZLGg/zC7QWUKfNLpE57m/S2yr1uEneIgsTgrSzXP3NXEsMkVn76OlaVVnzN+ugObuYGwhg== dependencies: - chalk "^2.0.0" - esutils "^2.0.2" - js-tokens "^4.0.0" + "@babel/helper-plugin-utils" "^7.22.5" -"@babel/parser@7.2.3": - version "7.2.3" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.2.3.tgz#32f5df65744b70888d17872ec106b02434ba1489" - integrity sha512-0LyEcVlfCoFmci8mXx8A5oIkpkOgyo8dRHtxBnK9RRBwxO2+JZPNsqtVEZQ7mJFPxnXF9lfmU24mHOPI0qnlkA== +"@babel/plugin-syntax-logical-assignment-operators@^7.8.3": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-logical-assignment-operators/-/plugin-syntax-logical-assignment-operators-7.10.4.tgz#ca91ef46303530448b906652bac2e9fe9941f699" + integrity sha512-d8waShlpFDinQ5MtvGU9xDAOzKH47+FFoney2baFIoMr952hKOLp1HR7VszoZvOsV/4+RRszNY7D17ba0te0ig== + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" + +"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" + integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/parser@^7.0.0", "@babel/parser@^7.2.2", "@babel/parser@^7.2.3": - version "7.3.1" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.3.1.tgz#8f4ffd45f779e6132780835ffa7a215fa0b2d181" - integrity sha512-ATz6yX/L8LEnC3dtLQnIx4ydcPxhLcoy9Vl6re00zb2w5lG6itY6Vhnr1KFRPq/FHNsgl/gh2mjNN20f9iJTTA== +"@babel/plugin-syntax-numeric-separator@^7.8.3": + version "7.10.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.10.4.tgz#b9b070b3e33570cd9fd07ba7fa91c0dd37b9af97" + integrity sha512-9H6YdfkcK/uOnY/K7/aA2xpzaAgkQn37yzWUMRK7OaPOqOpGS1+n0H5hxT9AUw9EsSjPW8SVyMJwYRtWs3X3ug== + dependencies: + "@babel/helper-plugin-utils" "^7.10.4" -"@babel/parser@^7.1.0": - version "7.3.4" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.3.4.tgz#a43357e4bbf4b92a437fb9e465c192848287f27c" - integrity sha512-tXZCqWtlOOP4wgCp6RjRvLmfuhnqTLy9VHwRochJBCP2nDm27JnnuFEnXFASVyQNHk36jD1tAammsCEEqgscIQ== +"@babel/plugin-syntax-object-rest-spread@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" + integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== + dependencies: + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-object-rest-spread@^7.0.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.2.0.tgz#3b7a3e733510c57e820b9142a6579ac8b0dfad2e" - integrity sha512-t0JKGgqk2We+9may3t0xDdmneaXmyxq0xieYcKHxIsrJO64n1OiMWNUtc5gQK1PA0NpdCRrtZp4z+IUaKugrSA== +"@babel/plugin-syntax-optional-catch-binding@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" + integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/runtime@^7.2.0": - version "7.3.4" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.3.4.tgz#73d12ba819e365fcf7fd152aed56d6df97d21c83" - integrity sha512-IvfvnMdSaLBateu0jfsYIpZTxAc2cKEXEMiezGGN75QcBcecDUKd3PgLAncT0oOgxKy8dd8hrJKj9MfzgfZd6g== +"@babel/plugin-syntax-optional-chaining@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" + integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== dependencies: - regenerator-runtime "^0.12.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/template@^7.0.0", "@babel/template@^7.1.0", "@babel/template@^7.1.2", "@babel/template@^7.2.2": - version "7.2.2" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.2.2.tgz#005b3fdf0ed96e88041330379e0da9a708eb2907" - integrity sha512-zRL0IMM02AUDwghf5LMSSDEz7sBCO2YnNmpg3uWTZj/v1rcG2BmQUvaGU8GhU8BvfMh1k2KIAYZ7Ji9KXPUg7g== +"@babel/plugin-syntax-top-level-await@^7.8.3": + version "7.14.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.14.5.tgz#c1cfdadc35a646240001f06138247b741c34d94c" + integrity sha512-hx++upLv5U1rgYfwe1xBQUhRmU41NEvpUvrp8jkrSCdvGSnM5/qdRMtylJ6PG5OFkBaHkbTAKTnd3/YyESRHFw== dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/parser" "^7.2.2" - "@babel/types" "^7.2.2" + "@babel/helper-plugin-utils" "^7.14.5" -"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.1.5", "@babel/traverse@^7.2.2": - version "7.2.3" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.2.3.tgz#7ff50cefa9c7c0bd2d81231fdac122f3957748d8" - integrity sha512-Z31oUD/fJvEWVR0lNZtfgvVt512ForCTNKYcJBGbPb1QZfve4WGH8Wsy7+Mev33/45fhP/hwQtvgusNdcCMgSw== +"@babel/plugin-syntax-typescript@^7.7.2": + version "7.23.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.23.3.tgz#24f460c85dbbc983cd2b9c4994178bcc01df958f" + integrity sha512-9EiNjVJOMwCO+43TqoTrgQ8jMwcAd0sWyXi9RPfIsLTj4R2MADDDQXELhffaUx/uJv2AYcxBgPwH6j4TIA4ytQ== dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/generator" "^7.2.2" - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-split-export-declaration" "^7.0.0" - "@babel/parser" "^7.2.3" - "@babel/types" "^7.2.2" + "@babel/helper-plugin-utils" "^7.22.5" + +"@babel/template@^7.22.15", "@babel/template@^7.3.3": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.22.15.tgz#09576efc3830f0430f4548ef971dde1350ef2f38" + integrity sha512-QPErUVm4uyJa60rkI73qneDacvdvzxshT3kksGqlGWYdOTIUOwJ7RDUL8sGqslY1uXWSL6xMFKEXDS3ox2uF0w== + dependencies: + "@babel/code-frame" "^7.22.13" + "@babel/parser" "^7.22.15" + "@babel/types" "^7.22.15" + +"@babel/traverse@^7.23.3", "@babel/traverse@^7.23.4": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.23.4.tgz#c2790f7edf106d059a0098770fe70801417f3f85" + integrity sha512-IYM8wSUwunWTB6tFC2dkKZhxbIjHoWemdK+3f8/wq8aKhbUscxD5MX72ubd90fxvFknaLPeGw5ycU84V1obHJg== + dependencies: + "@babel/code-frame" "^7.23.4" + "@babel/generator" "^7.23.4" + "@babel/helper-environment-visitor" "^7.22.20" + "@babel/helper-function-name" "^7.23.0" + "@babel/helper-hoist-variables" "^7.22.5" + "@babel/helper-split-export-declaration" "^7.22.6" + "@babel/parser" "^7.23.4" + "@babel/types" "^7.23.4" debug "^4.1.0" globals "^11.1.0" - lodash "^4.17.10" -"@babel/types@^7.0.0", "@babel/types@^7.2.2", "@babel/types@^7.3.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.3.0.tgz#61dc0b336a93badc02bf5f69c4cd8e1353f2ffc0" - integrity sha512-QkFPw68QqWU1/RVPyBe8SO7lXbPfjtqAxRYQKpFpaB8yMq7X2qAqfwK5LKoQufEkSmO5NQ70O6Kc3Afk03RwXw== +"@babel/types@^7.0.0", "@babel/types@^7.20.7", "@babel/types@^7.22.15", "@babel/types@^7.22.5", "@babel/types@^7.23.0", "@babel/types@^7.23.3", "@babel/types@^7.23.4", "@babel/types@^7.3.3": + version "7.23.4" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.4.tgz#7206a1810fc512a7f7f7d4dace4cb4c1c9dbfb8e" + integrity sha512-7uIFwVYpoplT5jp/kVv6EF93VaJ8H+Yn5IczYiaAi98ajzjfoZfslet/e0sLh+wVBjb2qqIut1b0S26VSafsSQ== dependencies: - esutils "^2.0.2" - lodash "^4.17.10" + "@babel/helper-string-parser" "^7.23.4" + "@babel/helper-validator-identifier" "^7.22.20" to-fast-properties "^2.0.0" -"@cnakazawa/watch@^1.0.3": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.3.tgz#099139eaec7ebf07a27c1786a3ff64f39464d2ef" - integrity sha512-r5160ogAvGyHsal38Kux7YYtodEKOj89RGb28ht1jh3SJb08VwRwAKKJL0bGb04Zd/3r9FL3BFIc3bBidYffCA== +"@bcoe/v8-coverage@^0.2.3": + version "0.2.3" + resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" + integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== + +"@eslint-community/eslint-utils@^4.2.0": + version "4.4.0" + resolved "https://registry.yarnpkg.com/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz#a23514e8fb9af1269d5f7788aa556798d61c6b59" + integrity sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA== + dependencies: + eslint-visitor-keys "^3.3.0" + +"@eslint-community/regexpp@^4.12.1": + version "4.12.1" + resolved "https://registry.yarnpkg.com/@eslint-community/regexpp/-/regexpp-4.12.1.tgz#cfc6cffe39df390a3841cde2abccf92eaa7ae0e0" + integrity sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ== + +"@eslint/config-array@^0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@eslint/config-array/-/config-array-0.19.2.tgz#3060b809e111abfc97adb0bb1172778b90cb46aa" + integrity sha512-GNKqxfHG2ySmJOBSHg7LxeUx4xpuCoFjacmlCoYWEbaPXLwvfIjixRI12xCQZeULksQb23uiA8F40w5TojpV7w== + dependencies: + "@eslint/object-schema" "^2.1.6" + debug "^4.3.1" + minimatch "^3.1.2" + +"@eslint/core@^0.12.0": + version "0.12.0" + resolved "https://registry.yarnpkg.com/@eslint/core/-/core-0.12.0.tgz#5f960c3d57728be9f6c65bd84aa6aa613078798e" + integrity sha512-cmrR6pytBuSMTaBweKoGMwu3EiHiEC+DoyupPmlZ0HxBJBtIxwe+j/E4XPIKNx+Q74c8lXKPwYawBf5glsTkHg== + dependencies: + "@types/json-schema" "^7.0.15" + +"@eslint/eslintrc@^3.3.0": + version "3.3.0" + resolved "https://registry.yarnpkg.com/@eslint/eslintrc/-/eslintrc-3.3.0.tgz#96a558f45842989cca7ea1ecd785ad5491193846" + integrity sha512-yaVPAiNAalnCZedKLdR21GOGILMLKPyqSLWaAjQFvYA2i/ciDi8ArYVr69Anohb6cH2Ukhqti4aFnYyPm8wdwQ== + dependencies: + ajv "^6.12.4" + debug "^4.3.2" + espree "^10.0.1" + globals "^14.0.0" + ignore "^5.2.0" + import-fresh "^3.2.1" + js-yaml "^4.1.0" + minimatch "^3.1.2" + strip-json-comments "^3.1.1" + +"@eslint/js@9.21.0", "@eslint/js@^9.21.0": + version "9.21.0" + resolved "https://registry.yarnpkg.com/@eslint/js/-/js-9.21.0.tgz#4303ef4e07226d87c395b8fad5278763e9c15c08" + integrity sha512-BqStZ3HX8Yz6LvsF5ByXYrtigrV5AXADWLAGc7PH/1SxOb7/FIYYMszZZWiUou/GB9P2lXWk2SV4d+Z8h0nknw== + +"@eslint/object-schema@^2.1.6": + version "2.1.6" + resolved "https://registry.yarnpkg.com/@eslint/object-schema/-/object-schema-2.1.6.tgz#58369ab5b5b3ca117880c0f6c0b0f32f6950f24f" + integrity sha512-RBMg5FRL0I0gs51M/guSAj5/e14VQ4tpZnQNWwuDT66P14I43ItmPfIZRhO9fUVIPOAQXU47atlywZ/czoqFPA== + +"@eslint/plugin-kit@^0.2.7": + version "0.2.7" + resolved "https://registry.yarnpkg.com/@eslint/plugin-kit/-/plugin-kit-0.2.7.tgz#9901d52c136fb8f375906a73dcc382646c3b6a27" + integrity sha512-JubJ5B2pJ4k4yGxaNLdbjrnk9d/iDz6/q8wOilpIowd6PJPgaxCuHBnBszq7Ce2TyMrywm5r4PnKm6V3iiZF+g== + dependencies: + "@eslint/core" "^0.12.0" + levn "^0.4.1" + +"@humanfs/core@^0.19.1": + version "0.19.1" + resolved "https://registry.yarnpkg.com/@humanfs/core/-/core-0.19.1.tgz#17c55ca7d426733fe3c561906b8173c336b40a77" + integrity sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA== + +"@humanfs/node@^0.16.6": + version "0.16.6" + resolved "https://registry.yarnpkg.com/@humanfs/node/-/node-0.16.6.tgz#ee2a10eaabd1131987bf0488fd9b820174cd765e" + integrity sha512-YuI2ZHQL78Q5HbhDiBA1X4LmYdXCKCMQIfw0pw7piHJwyREFebJUvrQN4cMssyES6x+vfUbx1CIpaQUKYdQZOw== + dependencies: + "@humanfs/core" "^0.19.1" + "@humanwhocodes/retry" "^0.3.0" + +"@humanwhocodes/module-importer@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz#af5b2691a22b44be847b0ca81641c5fb6ad0172c" + integrity sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA== + +"@humanwhocodes/retry@^0.3.0": + version "0.3.1" + resolved "https://registry.yarnpkg.com/@humanwhocodes/retry/-/retry-0.3.1.tgz#c72a5c76a9fbaf3488e231b13dc52c0da7bab42a" + integrity sha512-JBxkERygn7Bv/GbN5Rv8Ul6LVknS+5Bp6RgDC/O8gEBU/yeH5Ui5C/OlWrTb6qct7LjjfT6Re2NxB0ln0yYybA== + +"@humanwhocodes/retry@^0.4.2": + version "0.4.2" + resolved "https://registry.yarnpkg.com/@humanwhocodes/retry/-/retry-0.4.2.tgz#1860473de7dfa1546767448f333db80cb0ff2161" + integrity sha512-xeO57FpIu4p1Ri3Jq/EXq4ClRm86dVF2z/+kvFnyqVYRavTZmaFaUBbWCOuuTh0o/g7DSsk6kc2vrS4Vl5oPOQ== + +"@istanbuljs/load-nyc-config@^1.0.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@istanbuljs/load-nyc-config/-/load-nyc-config-1.1.0.tgz#fd3db1d59ecf7cf121e80650bb86712f9b55eced" + integrity sha512-VjeHSlIzpv/NyD3N0YuHfXOPDIixcA1q2ZV98wsMqcYlPmv2n3Yb2lYP9XMElnaFVXg5A7YLTeLu6V84uQDjmQ== dependencies: - exec-sh "^0.3.2" - minimist "^1.2.0" + camelcase "^5.3.1" + find-up "^4.1.0" + get-package-type "^0.1.0" + js-yaml "^3.13.1" + resolve-from "^5.0.0" + +"@istanbuljs/schema@^0.1.2": + version "0.1.3" + resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" + integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== -"@jest/console@^24.3.0": - version "24.3.0" - resolved "https://registry.yarnpkg.com/@jest/console/-/console-24.3.0.tgz#7bd920d250988ba0bf1352c4493a48e1cb97671e" - integrity sha512-NaCty/OOei6rSDcbPdMiCbYCI0KGFGPgGO6B09lwWt5QTxnkuhKYET9El5u5z1GAcSxkQmSMtM63e24YabCWqA== +"@jest/console@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/console/-/console-29.7.0.tgz#cd4822dbdb84529265c5a2bdb529a3c9cc950ffc" + integrity sha512-5Ni4CU7XHQi32IJ398EEP4RrB8eV09sXP2ROqD4bksHrnTree52PsxvX8tpL8LvTZ3pFzXyPbNQReSN41CAhOg== dependencies: - "@jest/source-map" "^24.3.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + slash "^3.0.0" + +"@jest/core@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/core/-/core-29.7.0.tgz#b6cccc239f30ff36609658c5a5e2291757ce448f" + integrity sha512-n7aeXWKMnGtDA48y8TLWJPJmLmmZ642Ceo78cYWEpiD7FzDgmNDV/GCVRorPABdXLJZ/9wzzgZAlHjXjxDHGsg== + dependencies: + "@jest/console" "^29.7.0" + "@jest/reporters" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" - chalk "^2.0.1" - slash "^2.0.0" - -"@jest/core@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/core/-/core-24.5.0.tgz#2cefc6a69e9ebcae1da8f7c75f8a257152ba1ec0" - integrity sha512-RDZArRzAs51YS7dXG1pbXbWGxK53rvUu8mCDYsgqqqQ6uSOaTjcVyBl2Jce0exT2rSLk38ca7az7t2f3b0/oYQ== - dependencies: - "@jest/console" "^24.3.0" - "@jest/reporters" "^24.5.0" - "@jest/test-result" "^24.5.0" - "@jest/transform" "^24.5.0" - "@jest/types" "^24.5.0" - ansi-escapes "^3.0.0" - chalk "^2.0.1" + ansi-escapes "^4.2.1" + chalk "^4.0.0" + ci-info "^3.2.0" exit "^0.1.2" - graceful-fs "^4.1.15" - jest-changed-files "^24.5.0" - jest-config "^24.5.0" - jest-haste-map "^24.5.0" - jest-message-util "^24.5.0" - jest-regex-util "^24.3.0" - jest-resolve-dependencies "^24.5.0" - jest-runner "^24.5.0" - jest-runtime "^24.5.0" - jest-snapshot "^24.5.0" - jest-util "^24.5.0" - jest-validate "^24.5.0" - jest-watcher "^24.5.0" - micromatch "^3.1.10" - p-each-series "^1.0.0" - pirates "^4.0.1" - realpath-native "^1.1.0" - rimraf "^2.5.4" - strip-ansi "^5.0.0" - -"@jest/environment@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-24.5.0.tgz#a2557f7808767abea3f9e4cc43a172122a63aca8" - integrity sha512-tzUHR9SHjMXwM8QmfHb/EJNbF0fjbH4ieefJBvtwO8YErLTrecc1ROj0uo2VnIT6SlpEGZnvdCK6VgKYBo8LsA== - dependencies: - "@jest/fake-timers" "^24.5.0" - "@jest/transform" "^24.5.0" - "@jest/types" "^24.5.0" + graceful-fs "^4.2.9" + jest-changed-files "^29.7.0" + jest-config "^29.7.0" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-resolve-dependencies "^29.7.0" + jest-runner "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + jest-watcher "^29.7.0" + micromatch "^4.0.4" + pretty-format "^29.7.0" + slash "^3.0.0" + strip-ansi "^6.0.0" + +"@jest/environment@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/environment/-/environment-29.7.0.tgz#24d61f54ff1f786f3cd4073b4b94416383baf2a7" + integrity sha512-aQIfHDq33ExsN4jP1NWGXhxgQ/wixs60gDiKO+XVMd8Mn0NWPWgc34ZQDTb2jKaUWQ7MuwoitXAsN2XVXNMpAw== + dependencies: + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" - jest-mock "^24.5.0" + jest-mock "^29.7.0" + +"@jest/expect-utils@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect-utils/-/expect-utils-29.7.0.tgz#023efe5d26a8a70f21677d0a1afc0f0a44e3a1c6" + integrity sha512-GlsNBWiFQFCVi9QVSx7f5AgMeLxe9YCCs5PuP2O2LdjDAA8Jh9eX7lA1Jq/xdXw3Wb3hyvlFNfZIfcRetSzYcA== + dependencies: + jest-get-type "^29.6.3" -"@jest/fake-timers@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-24.5.0.tgz#4a29678b91fd0876144a58f8d46e6c62de0266f0" - integrity sha512-i59KVt3QBz9d+4Qr4QxsKgsIg+NjfuCjSOWj3RQhjF5JNy+eVJDhANQ4WzulzNCHd72srMAykwtRn5NYDGVraw== +"@jest/expect@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/expect/-/expect-29.7.0.tgz#76a3edb0cb753b70dfbfe23283510d3d45432bf2" + integrity sha512-8uMeAMycttpva3P1lBHB8VciS9V0XAr3GymPpipdyQXbBcuhkLQOSe8E/p92RyAdToS6ZD1tFkX+CkhoECE0dQ== dependencies: - "@jest/types" "^24.5.0" + expect "^29.7.0" + jest-snapshot "^29.7.0" + +"@jest/fake-timers@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/fake-timers/-/fake-timers-29.7.0.tgz#fd91bf1fffb16d7d0d24a426ab1a47a49881a565" + integrity sha512-q4DH1Ha4TTFPdxLsqDXK1d3+ioSL7yL5oCMJZgDYm6i+6CygW5E5xVr/D1HdsGxjt1ZWSfUAs9OxSB/BNelWrQ== + dependencies: + "@jest/types" "^29.6.3" + "@sinonjs/fake-timers" "^10.0.2" "@types/node" "*" - jest-message-util "^24.5.0" - jest-mock "^24.5.0" - -"@jest/reporters@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-24.5.0.tgz#9363a210d0daa74696886d9cb294eb8b3ad9b4d9" - integrity sha512-vfpceiaKtGgnuC3ss5czWOihKOUSyjJA4M4udm6nH8xgqsuQYcyDCi4nMMcBKsHXWgz9/V5G7iisnZGfOh1w6Q== - dependencies: - "@jest/environment" "^24.5.0" - "@jest/test-result" "^24.5.0" - "@jest/transform" "^24.5.0" - "@jest/types" "^24.5.0" - chalk "^2.0.1" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-util "^29.7.0" + +"@jest/globals@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/globals/-/globals-29.7.0.tgz#8d9290f9ec47ff772607fa864ca1d5a2efae1d4d" + integrity sha512-mpiz3dutLbkW2MNFubUGUEVLkTGiqW6yLVTA+JbP6fI6J5iL9Y0Nlg8k95pcF8ctKwCS7WVxteBs29hhfAotzQ== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/types" "^29.6.3" + jest-mock "^29.7.0" + +"@jest/reporters@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/reporters/-/reporters-29.7.0.tgz#04b262ecb3b8faa83b0b3d321623972393e8f4c7" + integrity sha512-DApq0KJbJOEzAFYjHADNNxAE3KbhxQB1y5Kplb5Waqw6zVbuWatSnMjE5gs8FUgEPmNsnZA3NCWl9NG0ia04Pg== + dependencies: + "@bcoe/v8-coverage" "^0.2.3" + "@jest/console" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" + "@types/node" "*" + chalk "^4.0.0" + collect-v8-coverage "^1.0.0" exit "^0.1.2" - glob "^7.1.2" - istanbul-api "^2.1.1" - istanbul-lib-coverage "^2.0.2" - istanbul-lib-instrument "^3.0.1" - istanbul-lib-source-maps "^3.0.1" - jest-haste-map "^24.5.0" - jest-resolve "^24.5.0" - jest-runtime "^24.5.0" - jest-util "^24.5.0" - jest-worker "^24.4.0" - node-notifier "^5.2.1" - slash "^2.0.0" - source-map "^0.6.0" - string-length "^2.0.0" + glob "^7.1.3" + graceful-fs "^4.2.9" + istanbul-lib-coverage "^3.0.0" + istanbul-lib-instrument "^6.0.0" + istanbul-lib-report "^3.0.0" + istanbul-lib-source-maps "^4.0.0" + istanbul-reports "^3.1.3" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + jest-worker "^29.7.0" + slash "^3.0.0" + string-length "^4.0.1" + strip-ansi "^6.0.0" + v8-to-istanbul "^9.0.1" + +"@jest/schemas@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-29.6.3.tgz#430b5ce8a4e0044a7e3819663305a7b3091c8e03" + integrity sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA== + dependencies: + "@sinclair/typebox" "^0.27.8" + +"@jest/source-map@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-29.6.3.tgz#d90ba772095cf37a34a5eb9413f1b562a08554c4" + integrity sha512-MHjT95QuipcPrpLM+8JMSzFx6eHp5Bm+4XeFDJlwsvVBjmKNiIAvasGK2fxz2WbGRlnvqehFbh07MMa7n3YJnw== + dependencies: + "@jridgewell/trace-mapping" "^0.3.18" + callsites "^3.0.0" + graceful-fs "^4.2.9" + +"@jest/test-result@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-29.7.0.tgz#8db9a80aa1a097bb2262572686734baed9b1657c" + integrity sha512-Fdx+tv6x1zlkJPcWXmMDAG2HBnaR9XPSd5aDWQVsfrZmLVT3lU1cwyxLgRmXR9yrq4NBoEm9BMsfgFzTQAbJYA== + dependencies: + "@jest/console" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/istanbul-lib-coverage" "^2.0.0" + collect-v8-coverage "^1.0.0" + +"@jest/test-sequencer@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/test-sequencer/-/test-sequencer-29.7.0.tgz#6cef977ce1d39834a3aea887a1726628a6f072ce" + integrity sha512-GQwJ5WZVrKnOJuiYiAF52UNUJXgTZx1NHjFSEB0qEMmSZKAkdMoIzw/Cj6x6NF4AvV23AUqDpFzQkN/eYCYTxw== + dependencies: + "@jest/test-result" "^29.7.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + slash "^3.0.0" + +"@jest/transform@^29.7.0": + version "29.7.0" + resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-29.7.0.tgz#df2dd9c346c7d7768b8a06639994640c642e284c" + integrity sha512-ok/BTPFzFKVMwO5eOHRrvnBVHdRy9IrsrW1GpMaQ9MCnilNLXQKmAX8s1YXDFaai9xJpac2ySzV0YeRRECr2Vw== + dependencies: + "@babel/core" "^7.11.6" + "@jest/types" "^29.6.3" + "@jridgewell/trace-mapping" "^0.3.18" + babel-plugin-istanbul "^6.1.1" + chalk "^4.0.0" + convert-source-map "^2.0.0" + fast-json-stable-stringify "^2.1.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" + micromatch "^4.0.4" + pirates "^4.0.4" + slash "^3.0.0" + write-file-atomic "^4.0.2" + +"@jest/types@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-29.6.3.tgz#1131f8cf634e7e84c5e77bab12f052af585fba59" + integrity sha512-u3UPsIilWKOM3F9CXtrG8LEJmNxwoCQC/XVj4IKYXvvpx7QIi/Kg1LI5uDmDpKlac62NUtX7eLjRh+jVZcLOzw== + dependencies: + "@jest/schemas" "^29.6.3" + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^3.0.0" + "@types/node" "*" + "@types/yargs" "^17.0.8" + chalk "^4.0.0" -"@jest/source-map@^24.3.0": - version "24.3.0" - resolved "https://registry.yarnpkg.com/@jest/source-map/-/source-map-24.3.0.tgz#563be3aa4d224caf65ff77edc95cd1ca4da67f28" - integrity sha512-zALZt1t2ou8le/crCeeiRYzvdnTzaIlpOWaet45lNSqNJUnXbppUUFR4ZUAlzgDmKee4Q5P/tKXypI1RiHwgag== +"@jridgewell/gen-mapping@^0.3.0", "@jridgewell/gen-mapping@^0.3.2": + version "0.3.3" + resolved "https://registry.yarnpkg.com/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz#7e02e6eb5df901aaedb08514203b096614024098" + integrity sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ== dependencies: - callsites "^3.0.0" - graceful-fs "^4.1.15" - source-map "^0.6.0" + "@jridgewell/set-array" "^1.0.1" + "@jridgewell/sourcemap-codec" "^1.4.10" + "@jridgewell/trace-mapping" "^0.3.9" -"@jest/test-result@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/test-result/-/test-result-24.5.0.tgz#ab66fb7741a04af3363443084e72ea84861a53f2" - integrity sha512-u66j2vBfa8Bli1+o3rCaVnVYa9O8CAFZeqiqLVhnarXtreSXG33YQ6vNYBogT7+nYiFNOohTU21BKiHlgmxD5A== - dependencies: - "@jest/console" "^24.3.0" - "@jest/types" "^24.5.0" - "@types/istanbul-lib-coverage" "^1.1.0" - -"@jest/transform@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/transform/-/transform-24.5.0.tgz#6709fc26db918e6af63a985f2cc3c464b4cf99d9" - integrity sha512-XSsDz1gdR/QMmB8UCKlweAReQsZrD/DK7FuDlNo/pE8EcKMrfi2kqLRk8h8Gy/PDzgqJj64jNEzOce9pR8oj1w== - dependencies: - "@babel/core" "^7.1.0" - "@jest/types" "^24.5.0" - babel-plugin-istanbul "^5.1.0" - chalk "^2.0.1" - convert-source-map "^1.4.0" - fast-json-stable-stringify "^2.0.0" - graceful-fs "^4.1.15" - jest-haste-map "^24.5.0" - jest-regex-util "^24.3.0" - jest-util "^24.5.0" - micromatch "^3.1.10" - realpath-native "^1.1.0" - slash "^2.0.0" - source-map "^0.6.1" - write-file-atomic "2.4.1" +"@jridgewell/resolve-uri@^3.1.0": + version "3.1.1" + resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.1.tgz#c08679063f279615a3326583ba3a90d1d82cc721" + integrity sha512-dSYZh7HhCDtCKm4QakX0xFpsRDqjjtZf/kjI/v3T3Nwt5r8/qz/M19F9ySyOqU94SXBmeG9ttTul+YnR4LOxFA== + +"@jridgewell/set-array@^1.0.1": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@jridgewell/set-array/-/set-array-1.1.2.tgz#7c6cf998d6d20b914c0a55a91ae928ff25965e72" + integrity sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw== + +"@jridgewell/sourcemap-codec@^1.4.10", "@jridgewell/sourcemap-codec@^1.4.14": + version "1.4.15" + resolved "https://registry.yarnpkg.com/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz#d7c6e6755c78567a951e04ab52ef0fd26de59f32" + integrity sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg== -"@jest/types@^24.5.0": - version "24.5.0" - resolved "https://registry.yarnpkg.com/@jest/types/-/types-24.5.0.tgz#feee214a4d0167b0ca447284e95a57aa10b3ee95" - integrity sha512-kN7RFzNMf2R8UDadPOl6ReyI+MT8xfqRuAnuVL+i4gwjv/zubdDK+EDeLHYwq1j0CSSR2W/MmgaRlMZJzXdmVA== +"@jridgewell/trace-mapping@^0.3.12", "@jridgewell/trace-mapping@^0.3.17", "@jridgewell/trace-mapping@^0.3.18", "@jridgewell/trace-mapping@^0.3.9": + version "0.3.20" + resolved "https://registry.yarnpkg.com/@jridgewell/trace-mapping/-/trace-mapping-0.3.20.tgz#72e45707cf240fa6b081d0366f8265b0cd10197f" + integrity sha512-R8LcPeWZol2zR8mmH3JeKQ6QRCFb7XgUhV9ZlGhHLGyg4wpPiPZNQOOWhFZhxKw8u//yTbNGI42Bx/3paXEQ+Q== dependencies: - "@types/istanbul-lib-coverage" "^1.1.0" - "@types/yargs" "^12.0.9" + "@jridgewell/resolve-uri" "^3.1.0" + "@jridgewell/sourcemap-codec" "^1.4.14" -"@mrmlnc/readdir-enhanced@^2.2.1": - version "2.2.1" - resolved "https://registry.yarnpkg.com/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde" - integrity sha512-bPHp6Ji8b41szTOcaP63VlnbbO5Ny6dwAATtY6JTjh5N2OLrb5Qk/Th5cRkRQhkWCt+EJsYrNB0MiL+Gpn6e3g== +"@sinclair/typebox@^0.27.8": + version "0.27.8" + resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" + integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== + +"@sinonjs/commons@^3.0.0": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@sinonjs/commons/-/commons-3.0.0.tgz#beb434fe875d965265e04722ccfc21df7f755d72" + integrity sha512-jXBtWAF4vmdNmZgD5FoKsVLv3rPgDnLgPbU84LIJ3otV44vJlDRokVng5v8NFJdCf/da9legHcKaRuZs4L7faA== dependencies: - call-me-maybe "^1.0.1" - glob-to-regexp "^0.3.0" + type-detect "4.0.8" -"@nodelib/fs.stat@^1.1.2": - version "1.1.3" - resolved "https://registry.yarnpkg.com/@nodelib/fs.stat/-/fs.stat-1.1.3.tgz#2b5a3ab3f918cca48a8c754c08168e3f03eba61b" - integrity sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw== +"@sinonjs/fake-timers@^10.0.2": + version "10.3.0" + resolved "https://registry.yarnpkg.com/@sinonjs/fake-timers/-/fake-timers-10.3.0.tgz#55fdff1ecab9f354019129daf4df0dd4d923ea66" + integrity sha512-V4BG07kuYSUkTCSBHG8G8TNhM+F19jXFWnQtzj+we8DrkpSBCee9Z3Ms8yiGer/dlmhe35/Xdgyo3/0rQKg7YA== + dependencies: + "@sinonjs/commons" "^3.0.0" -"@types/babel__core@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.0.tgz#710f2487dda4dcfd010ca6abb2b4dc7394365c51" - integrity sha512-wJTeJRt7BToFx3USrCDs2BhEi4ijBInTQjOIukj6a/5tEkwpFMVZ+1ppgmE+Q/FQyc5P/VWUbx7I9NELrKruHA== +"@types/babel__core@^7.1.14": + version "7.20.4" + resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.4.tgz#26a87347e6c6f753b3668398e34496d6d9ac6ac0" + integrity sha512-mLnSC22IC4vcWiuObSRjrLd9XcBTGf59vUSoq2jkQDJ/QQ8PMI9rSuzE+aEV8karUMbskw07bKYoUJCKTUaygg== dependencies: - "@babel/parser" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/parser" "^7.20.7" + "@babel/types" "^7.20.7" "@types/babel__generator" "*" "@types/babel__template" "*" "@types/babel__traverse" "*" "@types/babel__generator@*": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.0.2.tgz#d2112a6b21fad600d7674274293c85dce0cb47fc" - integrity sha512-NHcOfab3Zw4q5sEE2COkpfXjoE7o+PmqD9DQW4koUT3roNxwziUdXGnRndMat/LJNUtePwn1TlP4do3uoe3KZQ== + version "7.6.7" + resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.7.tgz#a7aebf15c7bc0eb9abd638bdb5c0b8700399c9d0" + integrity sha512-6Sfsq+EaaLrw4RmdFWE9Onp63TOUue71AWb4Gpa6JxzgTYtimbM086WnYTy2U67AofR++QKCo08ZP6pwx8YFHQ== dependencies: "@babel/types" "^7.0.0" "@types/babel__template@*": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.0.2.tgz#4ff63d6b52eddac1de7b975a5223ed32ecea9307" - integrity sha512-/K6zCpeW7Imzgab2bLkLEbz0+1JlFSrUMdw7KoIIu+IUdu51GWaBZpd3y1VXGVXzynvGa4DaIaxNZHiON3GXUg== + version "7.4.4" + resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.4.4.tgz#5672513701c1b2199bc6dad636a9d7491586766f" + integrity sha512-h/NUaSyG5EyxBIp8YRxo4RMe2/qQgvyowRwVMzhYhBCONbW8PUsg4lkFMrhgZhUe5z3L3MiLDuvyJ/CaPa2A8A== dependencies: "@babel/parser" "^7.1.0" "@babel/types" "^7.0.0" "@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": - version "7.0.6" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.6.tgz#328dd1a8fc4cfe3c8458be9477b219ea158fd7b2" - integrity sha512-XYVgHF2sQ0YblLRMLNPB3CkFMewzFmlDsH/TneZFHUXDlABQgh88uOxuez7ZcXxayLFrqLwtDH1t+FmlFwNZxw== + version "7.20.4" + resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.4.tgz#ec2c06fed6549df8bc0eb4615b683749a4a92e1b" + integrity sha512-mSM/iKUk5fDDrEV/e83qY+Cr3I1+Q3qqTuEn++HAWYjEa1+NxZr6CNrcJGf2ZTnq4HoFGC3zaTPZTobCzCFukA== dependencies: - "@babel/types" "^7.3.0" - -"@types/istanbul-lib-coverage@^1.1.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-1.1.0.tgz#2cc2ca41051498382b43157c8227fea60363f94a" - integrity sha512-ohkhb9LehJy+PA40rDtGAji61NCgdtKLAlFoYp4cnuuQEswwdK3vz9SOIkkyc3wrk8dzjphQApNs56yyXLStaQ== + "@babel/types" "^7.20.7" -"@types/node@*": - version "11.10.5" - resolved "https://registry.yarnpkg.com/@types/node/-/node-11.10.5.tgz#fbaca34086bdc118011e1f05c47688d432f2d571" - integrity sha512-DuIRlQbX4K+d5I+GMnv+UfnGh+ist0RdlvOp+JZ7ePJ6KQONCFQv/gKYSU1ZzbVdFSUCKZOltjmpFAGGv5MdYA== - -"@types/stack-utils@^1.0.1": - version "1.0.1" - resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-1.0.1.tgz#0a851d3bd96498fa25c33ab7278ed3bd65f06c3e" - integrity sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw== +"@types/estree@^1.0.6": + version "1.0.6" + resolved "https://registry.yarnpkg.com/@types/estree/-/estree-1.0.6.tgz#628effeeae2064a1b4e79f78e81d87b7e5fc7b50" + integrity sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw== -"@types/yargs@^12.0.2", "@types/yargs@^12.0.9": - version "12.0.9" - resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-12.0.9.tgz#693e76a52f61a2f1e7fb48c0eef167b95ea4ffd0" - integrity sha512-sCZy4SxP9rN2w30Hlmg5dtdRwgYQfYRiLo9usw8X9cxlf+H4FqM1xX7+sNH7NNKVdbXMJWqva7iyy+fxh/V7fA== +"@types/graceful-fs@^4.1.3": + version "4.1.9" + resolved "https://registry.yarnpkg.com/@types/graceful-fs/-/graceful-fs-4.1.9.tgz#2a06bc0f68a20ab37b3e36aa238be6abdf49e8b4" + integrity sha512-olP3sd1qOEe5dXTSaFvQG+02VdRXcdytWLAZsAq1PecU8uqQAhkrnbli7DagjtXKW/Bl7YJbUsa8MPcuc8LHEQ== + dependencies: + "@types/node" "*" -abab@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.4.tgz#5faad9c2c07f60dd76770f71cf025b62a63cfd4e" - integrity sha1-X6rZwsB/YN12dw9xzwJbYqY8/U4= +"@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0", "@types/istanbul-lib-coverage@^2.0.1": + version "2.0.6" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz#7739c232a1fee9b4d3ce8985f314c0c6d33549d7" + integrity sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w== -acorn-globals@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/acorn-globals/-/acorn-globals-4.1.0.tgz#ab716025dbe17c54d3ef81d32ece2b2d99fe2538" - integrity sha512-KjZwU26uG3u6eZcfGbTULzFcsoz6pegNKtHPksZPOUsiKo5bUmiBPa38FuHZ/Eun+XYh/JCCkS9AS3Lu4McQOQ== +"@types/istanbul-lib-report@*": + version "3.0.3" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.3.tgz#53047614ae72e19fc0401d872de3ae2b4ce350bf" + integrity sha512-NQn7AHQnk/RSLOxrBbGyJM/aVQ+pjj5HCgasFxc0K/KhoATfQ/47AyUl15I2yBUpihjmas+a+VJBOqecrFH+uA== dependencies: - acorn "^5.0.0" - -acorn-jsx@^5.0.0: - version "5.0.1" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.0.1.tgz#32a064fd925429216a09b141102bfdd185fae40e" - integrity sha512-HJ7CfNHrfJLlNTzIEUTj43LNWGkqpRLxm3YjAlcD0ACydk9XynzYsCBHxut+iqt+1aBXkx9UP/w/ZqMr13XIzg== + "@types/istanbul-lib-coverage" "*" -acorn@^5.0.0, acorn@^5.3.0: - version "5.5.3" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.5.3.tgz#f473dd47e0277a08e28e9bec5aeeb04751f0b8c9" - integrity sha512-jd5MkIUlbbmb07nXH0DT3y7rDVtkzDi4XZOUVWAer8ajmF/DTSSbl5oNFyDOl/OXA33Bl79+ypHhl2pN20VeOQ== +"@types/istanbul-reports@^3.0.0": + version "3.0.4" + resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-3.0.4.tgz#0f03e3d2f670fbdac586e34b433783070cc16f54" + integrity sha512-pk2B1NWalF9toCRu6gjBzR69syFjP4Od8WRAX+0mmf9lAjCRicLOWc+ZrxZHx/0XRjotgkF9t6iaMJ+aXcOdZQ== + dependencies: + "@types/istanbul-lib-report" "*" -acorn@^6.0.7: - version "6.1.1" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.1.1.tgz#7d25ae05bb8ad1f9b699108e1094ecd7884adc1f" - integrity sha512-jPTiwtOxaHNaAPg/dmrJ/beuzLRnXtB0kQPQ8JpotKJgTB6rX6c8mlf315941pyjBSaPg8NHXS9fhP4u17DpGA== +"@types/json-schema@^7.0.15": + version "7.0.15" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.15.tgz#596a1747233694d50f6ad8a7869fcb6f56cf5841" + integrity sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA== -ajv@^6.5.5, ajv@^6.9.1: - version "6.9.2" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.9.2.tgz#4927adb83e7f48e5a32b45729744c71ec39c9c7b" - integrity sha512-4UFy0/LgDo7Oa/+wOAlj44tp9K78u38E5/359eSrqEp1Z5PdVfimCcs7SluXMP755RUQu6d2b4AvF0R1C9RZjg== +"@types/node@*": + version "20.9.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.9.2.tgz#002815c8e87fe0c9369121c78b52e800fadc0ac6" + integrity sha512-WHZXKFCEyIUJzAwh3NyyTHYSR35SevJ6mZ1nWwJafKtiQbqRTIKSRcw3Ma3acqgsent3RRDqeVwpHntMk+9irg== dependencies: - fast-deep-equal "^2.0.1" + undici-types "~5.26.4" + +"@types/stack-utils@^2.0.0": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@types/stack-utils/-/stack-utils-2.0.3.tgz#6209321eb2c1712a7e7466422b8cb1fc0d9dd5d8" + integrity sha512-9aEbYZ3TbYMznPdcdr3SmIrLXwC/AKZXQeCf9Pgao5CKb8CyHuEX5jzWPTkvregvhRJHcpRO6BFoGW9ycaOkYw== + +"@types/yargs-parser@*": + version "21.0.3" + resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-21.0.3.tgz#815e30b786d2e8f0dcd85fd5bcf5e1a04d008f15" + integrity sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ== + +"@types/yargs@^17.0.8": + version "17.0.31" + resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-17.0.31.tgz#8fd0089803fd55d8a285895a18b88cb71a99683c" + integrity sha512-bocYSx4DI8TmdlvxqGpVNXOgCNR1Jj0gNPhhAY+iz1rgKDAaYrAYdFYnhDV1IFuiuVc9HkOwyDcFxaTElF3/wg== + dependencies: + "@types/yargs-parser" "*" + +acorn-jsx@^5.3.2: + version "5.3.2" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" + integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== + +acorn@^8.11.3: + version "8.11.3" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.11.3.tgz#71e0b14e13a4ec160724b38fb7b0f233b1b81d7a" + integrity sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg== + +acorn@^8.14.0: + version "8.14.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-8.14.1.tgz#721d5dc10f7d5b5609a891773d47731796935dfb" + integrity sha512-OvQ/2pUDKmgfCg++xsTX1wGxfTaszcHVcTctW4UJB4hibJx2HXxxO5UmVgyjMa+ZDsiaf5wWLXYpRWMmBI0QHg== + +ajv@^6.12.4: + version "6.12.6" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" + integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== + dependencies: + fast-deep-equal "^3.1.1" fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.4.1" uri-js "^4.2.2" -all-contributors-cli@^6.1.2: - version "6.2.0" - resolved "https://registry.yarnpkg.com/all-contributors-cli/-/all-contributors-cli-6.2.0.tgz#60d5c4a190ed330bb1905881a5095270433bde2d" - integrity sha512-ppAgu0gsyexeLR9vs9CrGJUZbQbP1ei6bRWkG3drvefjAjLOZeVq6Fjh/kSPDtsnWI/l6XAWWR2MQWuIwtd7Dg== - dependencies: - "@babel/runtime" "^7.2.0" - async "^2.0.0-rc.1" - chalk "^2.3.0" - inquirer "^6.2.1" - lodash "^4.11.2" - pify "^4.0.1" - request "^2.72.0" - yargs "^13.1.0" - -ansi-escapes@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.1.0.tgz#f73207bb81207d75fd6c83f125af26eea378ca30" - integrity sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw== - -ansi-escapes@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-3.2.0.tgz#8780b98ff9dbf5638152d1f1fe5c1d7b4442976b" - integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== - -ansi-regex@^2.0.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df" - integrity sha1-w7M6te42DYbg5ijwRorn7yfWVN8= - -ansi-regex@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-3.0.0.tgz#ed0317c322064f79466c02966bddb605ab37d998" - integrity sha1-7QMXwyIGT3lGbAKWa922Bas32Zg= +ansi-escapes@^4.2.1: + version "4.3.2" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.2.tgz#6b2291d1db7d98b6521d5f1efa42d0f3a9feb65e" + integrity sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ== + dependencies: + type-fest "^0.21.3" -ansi-regex@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.0.0.tgz#70de791edf021404c3fd615aa89118ae0432e5a9" - integrity sha512-iB5Dda8t/UqpPI/IjsejXu5jOGDrzn41wJyljwPH65VCIbk6+1BzFIMJGFwTNrYXT1CrD+B4l19U7awiQ8rk7w== +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== -ansi-styles@^3.2.0, ansi-styles@^3.2.1: +ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== dependencies: color-convert "^1.9.0" -anymatch@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" - integrity sha512-5teOsQWABXHHBFP9y3skS5P3d/WfWXpv3FUpy+LorMrNYaT9pI4oLMQX7jzQ2KklNpGpWHzdCXTDT2Y3XGlZBw== +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== dependencies: - micromatch "^3.1.4" - normalize-path "^2.1.1" + color-convert "^2.0.1" -append-transform@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/append-transform/-/append-transform-1.0.0.tgz#046a52ae582a228bd72f58acfbe2967c678759ab" - integrity sha512-P009oYkeHyU742iSZJzZZywj4QRJdnTWffaKuJQLablCZ1uz6/cW4yaRgcDaoQ+uwOxxnt0gRUcwfsNP2ri0gw== +ansi-styles@^5.0.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-5.2.0.tgz#07449690ad45777d1924ac2abb2fc8895dba836b" + integrity sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA== + +anymatch@^3.0.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.3.tgz#790c58b19ba1720a84205b57c618d5ad8524973e" + integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== dependencies: - default-require-extensions "^2.0.0" + normalize-path "^3.0.0" + picomatch "^2.0.4" argparse@^1.0.7: version "1.0.10" @@ -464,169 +814,75 @@ argparse@^1.0.7: dependencies: sprintf-js "~1.0.2" -arr-diff@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/arr-diff/-/arr-diff-4.0.0.tgz#d6461074febfec71e7e15235761a329a5dc7c520" - integrity sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA= - -arr-flatten@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/arr-flatten/-/arr-flatten-1.1.0.tgz#36048bbff4e7b47e136644316c99669ea5ae91f1" - integrity sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg== - -arr-union@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/arr-union/-/arr-union-3.1.0.tgz#e39b09aea9def866a8f206e288af63919bae39c4" - integrity sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ= - -array-equal@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/array-equal/-/array-equal-1.0.0.tgz#8c2a5ef2472fd9ea742b04c77a75093ba2757c93" - integrity sha1-jCpe8kcv2ep0KwTHenUJO6J1fJM= - -array-union@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/array-union/-/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39" - integrity sha1-mjRBDk9OPaI96jdb5b5w8kd47Dk= - dependencies: - array-uniq "^1.0.1" - -array-uniq@^1.0.1: - version "1.0.3" - resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" - integrity sha1-r2rId6Jcx/dOBYiUdThY39sk/bY= - -array-unique@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/array-unique/-/array-unique-0.3.2.tgz#a894b75d4bc4f6cd679ef3244a9fd8f46ae2d428" - integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= - -arrify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d" - integrity sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0= - -asn1@~0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.3.tgz#dac8787713c9966849fc8180777ebe9c1ddf3b86" - integrity sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y= - -assert-plus@1.0.0, assert-plus@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" - integrity sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU= - -assign-symbols@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" - integrity sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c= - -astral-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-1.0.0.tgz#6c8c3fb827dd43ee3918f27b82782ab7658a6fd9" - integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== - -async-limiter@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.0.tgz#78faed8c3d074ab81f22b4e985d79e8738f720f8" - integrity sha512-jp/uFnooOiO+L211eZOoSyzpOITMXx1rBITauYykG3BRYPu8h0UcxsPNB04RR5vo4Tyz3+ay17tR6JVf9qzYWg== - -async@^2.0.0-rc.1, async@^2.5.0, async@^2.6.1: - version "2.6.2" - resolved "https://registry.yarnpkg.com/async/-/async-2.6.2.tgz#18330ea7e6e313887f5d2f2a904bac6fe4dd5381" - integrity sha512-H1qVYh1MYhEEFLsP97cVKqCGo7KfCyTt6uEWqsTBr9SO84oK9Uwbyd/yCW+6rKJLHksBNUVWZDAjfS+Ccx0Bbg== - dependencies: - lodash "^4.17.11" - -asynckit@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" - integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= - -atob@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.1.tgz#ae2d5a729477f289d60dd7f96a6314a22dd6c22a" - integrity sha1-ri1acpR38onWDdf5amMUoi3Wwio= - -aws-sign2@~0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" - integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= - -aws4@^1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" - integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== - -babel-jest@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-24.5.0.tgz#0ea042789810c2bec9065f7c8ab4dc18e1d28559" - integrity sha512-0fKCXyRwxFTJL0UXDJiT2xYxO9Lu2vBd9n+cC+eDjESzcVG3s2DRGAxbzJX21fceB1WYoBjAh8pQ83dKcl003g== - dependencies: - "@jest/transform" "^24.5.0" - "@jest/types" "^24.5.0" - "@types/babel__core" "^7.1.0" - babel-plugin-istanbul "^5.1.0" - babel-preset-jest "^24.3.0" - chalk "^2.4.2" - slash "^2.0.0" - -babel-plugin-istanbul@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-5.1.0.tgz#6892f529eff65a3e2d33d87dc5888ffa2ecd4a30" - integrity sha512-CLoXPRSUWiR8yao8bShqZUIC6qLfZVVY3X1wj+QPNXu0wfmrRRfarh1LYy+dYMVI+bDj0ghy3tuqFFRFZmL1Nw== - dependencies: - find-up "^3.0.0" - istanbul-lib-instrument "^3.0.0" - test-exclude "^5.0.0" - -babel-plugin-jest-hoist@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-24.3.0.tgz#f2e82952946f6e40bb0a75d266a3790d854c8b5b" - integrity sha512-nWh4N1mVH55Tzhx2isvUN5ebM5CDUvIpXPZYMRazQughie/EqGnbR+czzoQlhUmJG9pPJmYDRhvocotb2THl1w== +argparse@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" + integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== + +babel-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-29.7.0.tgz#f4369919225b684c56085998ac63dbd05be020d5" + integrity sha512-BrvGY3xZSwEcCzKvKsCi2GgHqDqsYkOP4/by5xCgIwGXQxIEh+8ew3gmrE1y7XRR6LHZIj6yLYnUi/mm2KXKBg== + dependencies: + "@jest/transform" "^29.7.0" + "@types/babel__core" "^7.1.14" + babel-plugin-istanbul "^6.1.1" + babel-preset-jest "^29.6.3" + chalk "^4.0.0" + graceful-fs "^4.2.9" + slash "^3.0.0" + +babel-plugin-istanbul@^6.1.1: + version "6.1.1" + resolved "https://registry.yarnpkg.com/babel-plugin-istanbul/-/babel-plugin-istanbul-6.1.1.tgz#fa88ec59232fd9b4e36dbbc540a8ec9a9b47da73" + integrity sha512-Y1IQok9821cC9onCx5otgFfRm7Lm+I+wwxOx738M/WLPZ9Q42m4IG5W0FNX8WLL2gYMZo3JkuXIH2DOpWM+qwA== dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@istanbuljs/load-nyc-config" "^1.0.0" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-instrument "^5.0.4" + test-exclude "^6.0.0" + +babel-plugin-jest-hoist@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-29.6.3.tgz#aadbe943464182a8922c3c927c3067ff40d24626" + integrity sha512-ESAc/RJvGTFEzRwOTT4+lNDk/GNHMkKbNzsvT0qKRfDyyYTskxB5rnU2njIDYVxXCBHHEI1c0YwHob3WaYujOg== + dependencies: + "@babel/template" "^7.3.3" + "@babel/types" "^7.3.3" + "@types/babel__core" "^7.1.14" "@types/babel__traverse" "^7.0.6" -babel-preset-jest@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-24.3.0.tgz#db88497e18869f15b24d9c0e547d8e0ab950796d" - integrity sha512-VGTV2QYBa/Kn3WCOKdfS31j9qomaXSgJqi65B6o05/1GsJyj9LVhSljM9ro4S+IBGj/ENhNBuH9bpqzztKAQSw== - dependencies: - "@babel/plugin-syntax-object-rest-spread" "^7.0.0" - babel-plugin-jest-hoist "^24.3.0" - -babel-runtime@6.26.0, babel-runtime@~6.26.0: - version "6.26.0" - resolved "https://registry.yarnpkg.com/babel-runtime/-/babel-runtime-6.26.0.tgz#965c7058668e82b55d7bfe04ff2337bc8b5647fe" - integrity sha1-llxwWGaOgrVde/4E/yM3vItWR/4= - dependencies: - core-js "^2.4.0" - regenerator-runtime "^0.11.0" +babel-preset-current-node-syntax@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/babel-preset-current-node-syntax/-/babel-preset-current-node-syntax-1.0.1.tgz#b4399239b89b2a011f9ddbe3e4f401fc40cff73b" + integrity sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ== + dependencies: + "@babel/plugin-syntax-async-generators" "^7.8.4" + "@babel/plugin-syntax-bigint" "^7.8.3" + "@babel/plugin-syntax-class-properties" "^7.8.3" + "@babel/plugin-syntax-import-meta" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.3" + "@babel/plugin-syntax-logical-assignment-operators" "^7.8.3" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.8.3" + "@babel/plugin-syntax-object-rest-spread" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.3" + "@babel/plugin-syntax-top-level-await" "^7.8.3" + +babel-preset-jest@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/babel-preset-jest/-/babel-preset-jest-29.6.3.tgz#fa05fa510e7d493896d7b0dd2033601c840f171c" + integrity sha512-0B3bhxR6snWXJZtR/RliHTDPRgn1sNHOR0yVtq/IiQFyuOVjFS+wuio/R4gSNkyYmKmJB4wGZv2NZanmKmTnNA== + dependencies: + babel-plugin-jest-hoist "^29.6.3" + babel-preset-current-node-syntax "^1.0.0" balanced-match@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.0.tgz#89b4d199ab2bee49de164ea02b89ce462d71b767" - integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= - -base@^0.11.1: - version "0.11.2" - resolved "https://registry.yarnpkg.com/base/-/base-0.11.2.tgz#7bde5ced145b6d551a90db87f83c558b4eb48a8f" - integrity sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg== - dependencies: - cache-base "^1.0.1" - class-utils "^0.3.5" - component-emitter "^1.2.1" - define-property "^1.0.0" - isobject "^3.0.1" - mixin-deep "^1.2.0" - pascalcase "^0.1.1" - -bcrypt-pbkdf@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz#63bc5dcb61331b92bc05fd528953c33462a06f8d" - integrity sha1-Y7xdy2EzG5K8Bf1SiVPDNGKgb40= - dependencies: - tweetnacl "^0.14.3" + version "1.0.2" + resolved "https://registry.yarnpkg.com/balanced-match/-/balanced-match-1.0.2.tgz#e83e3a7e3f300b34cb9d87f615fa0cbf357690ee" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== brace-expansion@^1.1.7: version "1.1.11" @@ -636,99 +892,56 @@ brace-expansion@^1.1.7: balanced-match "^1.0.0" concat-map "0.0.1" -braces@^2.3.1: - version "2.3.2" - resolved "https://registry.yarnpkg.com/braces/-/braces-2.3.2.tgz#5979fd3f14cd531565e5fa2df1abfff1dfaee729" - integrity sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w== - dependencies: - arr-flatten "^1.1.0" - array-unique "^0.3.2" - extend-shallow "^2.0.1" - fill-range "^4.0.0" - isobject "^3.0.1" - repeat-element "^1.1.2" - snapdragon "^0.8.1" - snapdragon-node "^2.0.1" - split-string "^3.0.2" - to-regex "^3.0.1" - -browser-process-hrtime@^0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz#425d68a58d3447f02a04aa894187fce8af8b7b8e" - integrity sha1-Ql1opY00R/AqBKqJQYf86K+Le44= +braces@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== + dependencies: + fill-range "^7.0.1" -browser-resolve@^1.11.3: - version "1.11.3" - resolved "https://registry.yarnpkg.com/browser-resolve/-/browser-resolve-1.11.3.tgz#9b7cbb3d0f510e4cb86bdbd796124d28b5890af6" - integrity sha512-exDi1BYWB/6raKHmDTCicQfTkqwN5fioMFV4j8BsfMU4R2DK/QfZfK7kOVkmWCNANf0snkBzqGqAJBao9gZMdQ== +browserslist@^4.21.9: + version "4.22.1" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.22.1.tgz#ba91958d1a59b87dab6fed8dfbcb3da5e2e9c619" + integrity sha512-FEVc202+2iuClEhZhrWy6ZiAcRLvNMyYcxZ8raemul1DYVOVdFsbqckWLdsixQZCpJlwe77Z3UTalE7jsjnKfQ== dependencies: - resolve "1.1.7" + caniuse-lite "^1.0.30001541" + electron-to-chromium "^1.4.535" + node-releases "^2.0.13" + update-browserslist-db "^1.0.13" -bser@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/bser/-/bser-2.0.0.tgz#9ac78d3ed5d915804fd87acb158bc797147a1719" - integrity sha1-mseNPtXZFYBP2HrLFYvHlxR6Fxk= +bser@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.1.tgz#e6787da20ece9d07998533cfd9de6f5c38f4bc05" + integrity sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ== dependencies: node-int64 "^0.4.0" buffer-from@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.0.0.tgz#4cb8832d23612589b0406e9e2956c17f06fdf531" - integrity sha512-83apNb8KK0Se60UE1+4Ukbe3HbfELJ6UlI4ldtOGs7So4KD26orJM8hIY9lxdzP+UpItH1Yh/Y8GUvNFWFFRxA== - -builtin-modules@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/builtin-modules/-/builtin-modules-1.1.1.tgz#270f076c5a72c02f5b65a47df94c5fe3a278892f" - integrity sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8= - -byline@~5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/byline/-/byline-5.0.0.tgz#741c5216468eadc457b03410118ad77de8c1ddb1" - integrity sha1-dBxSFkaOrcRXsDQQEYrXfejB3bE= - -cache-base@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2" - integrity sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ== - dependencies: - collection-visit "^1.0.0" - component-emitter "^1.2.1" - get-value "^2.0.6" - has-value "^1.0.0" - isobject "^3.0.1" - set-value "^2.0.0" - to-object-path "^0.3.0" - union-value "^1.0.0" - unset-value "^1.0.0" - -call-me-maybe@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/call-me-maybe/-/call-me-maybe-1.0.1.tgz#26d208ea89e37b5cbde60250a15f031c16a4d66b" - integrity sha1-JtII6onje1y95gJQoV8DHBak1ms= + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== callsites@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.0.0.tgz#fb7eb569b72ad7a45812f93fd9430a3e410b3dd3" - integrity sha512-tWnkwu9YEq2uzlBDI4RcLn8jrFvF9AOi8PxDNU3hZZjJcjkcRAq3vCI+vZcg1SuxISDYe86k9VZFwAxDiJGoAw== + version "3.1.0" + resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" + integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== -camelcase@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.0.0.tgz#03295527d58bd3cd4aa75363f35b2e8d97be2f42" - integrity sha512-faqwZqnWxbxn+F1d399ygeamQNy3lPp/H9H6rNrqYh4FSVCtcY+3cub1MxA8o9mDd55mM8Aghuu/kuyYA6VTsA== +camelcase@^5.3.1: + version "5.3.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -capture-exit@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/capture-exit/-/capture-exit-1.2.0.tgz#1c5fcc489fd0ab00d4f1ac7ae1072e3173fbab6f" - integrity sha1-HF/MSJ/QqwDU8ax64QcuMXP7q28= - dependencies: - rsvp "^3.3.3" +camelcase@^6.2.0: + version "6.3.0" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-6.3.0.tgz#5685b95eb209ac9c0c177467778c9c84df58ba9a" + integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== -caseless@~0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" - integrity sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw= +caniuse-lite@^1.0.30001541: + version "1.0.30001563" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001563.tgz#aa68a64188903e98f36eb9c56e48fba0c1fe2a32" + integrity sha512-na2WUmOxnwIZtwnFI2CZ/3er0wdNzU7hN+cPYz/z2ajHThnkWjNBOpEPP4n+4r2WPM847JaMotaJE3bnfzjyKw== -chalk@2.4.2, chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.4.2, chalk@~2.4.1: +chalk@^2.4.2: version "2.4.2" resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== @@ -737,3617 +950,1697 @@ chalk@2.4.2, chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.4. escape-string-regexp "^1.0.5" supports-color "^5.3.0" -chardet@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" - integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== - -ci-info@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-2.0.0.tgz#67a9e964be31a51e15e5010d58e6f12834002f46" - integrity sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ== - -class-utils@^0.3.5: - version "0.3.6" - resolved "https://registry.yarnpkg.com/class-utils/-/class-utils-0.3.6.tgz#f93369ae8b9a7ce02fd41faad0ca83033190c463" - integrity sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg== +chalk@^4.0.0: + version "4.1.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== dependencies: - arr-union "^3.1.0" - define-property "^0.2.5" - isobject "^3.0.0" - static-extend "^0.1.1" + ansi-styles "^4.1.0" + supports-color "^7.1.0" -cli-cursor@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-2.1.0.tgz#b35dac376479facc3e94747d41d0d0f5238ffcb5" - integrity sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU= - dependencies: - restore-cursor "^2.0.0" +char-regex@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/char-regex/-/char-regex-1.0.2.tgz#d744358226217f981ed58f479b1d6bcc29545dcf" + integrity sha512-kWWXztvZ5SBQV+eRgKFeh8q5sLuZY2+8WUIzlxWVTg+oGwY14qylx1KbKzHd8P6ZYkAg0xyIDU9JMHhyJMZ1jw== -cli-width@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" - integrity sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk= +ci-info@^3.2.0: + version "3.9.0" + resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-3.9.0.tgz#4279a62028a7b1f262f3473fc9605f5e218c59b4" + integrity sha512-NIxF55hv4nSqQswkAeiOi1r83xy8JldOFDTWiug55KBu9Jnblncd2U6ViHmYgHf01TPZS77NJBhBMKdWj9HQMQ== -cliui@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz#348422dbe82d800b3022eef4f6ac10bf2e4d1b49" - integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== +cjs-module-lexer@^1.0.0: + version "1.2.3" + resolved "https://registry.yarnpkg.com/cjs-module-lexer/-/cjs-module-lexer-1.2.3.tgz#6c370ab19f8a3394e318fe682686ec0ac684d107" + integrity sha512-0TNiGstbQmCFwt4akjjBg5pLRTSyj/PkWQ1ZoO2zntmg9yLqSRxwEa4iCfQLGjqhiqBfOJa7W/E8wfGrTDmlZQ== + +cliui@^8.0.1: + version "8.0.1" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-8.0.1.tgz#0c04b075db02cbfe60dc8e6cf2f5486b1a3608aa" + integrity sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ== dependencies: - string-width "^2.1.1" - strip-ansi "^4.0.0" - wrap-ansi "^2.0.0" + string-width "^4.2.0" + strip-ansi "^6.0.1" + wrap-ansi "^7.0.0" co@^4.6.0: version "4.6.0" resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184" - integrity sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ= + integrity sha512-QVb0dM5HvG+uaxitm8wONl7jltx8dqhfU33DcqtOZcLSVIKSDDLDi7+0LbAKiyI8hD9u42m2YxXSkMGWThaecQ== -code-point-at@^1.0.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" - integrity sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c= +collect-v8-coverage@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/collect-v8-coverage/-/collect-v8-coverage-1.0.2.tgz#c0b29bcd33bcd0779a1344c2136051e6afd3d9e9" + integrity sha512-lHl4d5/ONEbLlJvaJNtsF/Lz+WvB07u2ycqTYbdrq7UypDXailES4valYb2eWiJFxZlVmpGekfqoxQhzyFdT4Q== -collection-visit@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/collection-visit/-/collection-visit-1.0.0.tgz#4bc0373c164bc3291b4d368c829cf1a80a59dca0" - integrity sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA= +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== dependencies: - map-visit "^1.0.0" - object-visit "^1.0.0" + color-name "1.1.3" -color-convert@^1.9.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.1.tgz#c1261107aeb2f294ebffec9ed9ecad529a6097ed" - integrity sha512-mjGanIiwQJskCC18rPR6OmrZ6fm2Lc7PeGFYwCmy5J34wC6F1PzdGL6xeMfmgicfYcNLGuVFA3WzXtIDCQSZxQ== +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== dependencies: - color-name "^1.1.1" + color-name "~1.1.4" -color-name@^1.1.1: +color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" - integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= - -combined-stream@^1.0.6, combined-stream@~1.0.6: - version "1.0.7" - resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.7.tgz#2d1d24317afb8abe95d6d2c0b07b57813539d828" - integrity sha512-brWl9y6vOB1xYPZcpZde3N9zDByXTosAeMDo4p1wzo6UMOX4vumB+TP1RZ76sfE6Md68Q0NJSrE/gbezd4Ul+w== - dependencies: - delayed-stream "~1.0.0" - -commander@~2.17.1: - version "2.17.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" - integrity sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg== + integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== -compare-versions@^3.2.1: - version "3.4.0" - resolved "https://registry.yarnpkg.com/compare-versions/-/compare-versions-3.4.0.tgz#e0747df5c9cb7f054d6d3dc3e1dbc444f9e92b26" - integrity sha512-tK69D7oNXXqUW3ZNo/z7NXTEz22TCF0pTE+YF9cxvaAM9XnkLo1fV621xCLrRR6aevJlKxExkss0vWqUCUpqdg== - -component-emitter@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/component-emitter/-/component-emitter-1.2.1.tgz#137918d6d78283f7df7a6b7c5a63e140e69425e6" - integrity sha1-E3kY1teCg/ffemt8WmPhQOaUJeY= +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" - integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= + integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== -contains-path@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/contains-path/-/contains-path-0.1.0.tgz#fe8cf184ff6670b6baef01a9d4861a5cbec4120a" - integrity sha1-/ozxhP9mcLa67wGp1IYaXL7EEgo= +convert-source-map@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-2.0.0.tgz#4b560f649fc4e918dd0ab75cf4961e8bc882d82a" + integrity sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg== -convert-source-map@^1.1.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" - integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== +create-jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/create-jest/-/create-jest-29.7.0.tgz#a355c5b3cb1e1af02ba177fe7afd7feee49a5320" + integrity sha512-Adz2bdH0Vq3F53KEMJOoftQFutWCukm6J24wbPWRO4k1kMY7gS7ds/uoJkNuV8wDCtWWnuwGcJwpWcih+zEW1Q== dependencies: - safe-buffer "~5.1.1" - -convert-source-map@^1.4.0: - version "1.5.1" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.5.1.tgz#b8278097b9bc229365de5c62cf5fcaed8b5599e5" - integrity sha1-uCeAl7m8IpNl3lxiz1/K7YtVmeU= - -copy-descriptor@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" - integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= + "@jest/types" "^29.6.3" + chalk "^4.0.0" + exit "^0.1.2" + graceful-fs "^4.2.9" + jest-config "^29.7.0" + jest-util "^29.7.0" + prompts "^2.0.1" -core-js@^2.4.0: - version "2.6.5" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.5.tgz#44bc8d249e7fb2ff5d00e0341a7ffb94fbf67895" - integrity sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A== +cross-spawn@^7.0.3: + version "7.0.3" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.3.tgz#f73a85b9d5d41d045551c177e2882d4ac85728a6" + integrity sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w== + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" -core-util-is@1.0.2, core-util-is@~1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" - integrity sha1-tf1UIgqivFq1eqtxQMlAdUUDwac= +cross-spawn@^7.0.6: + version "7.0.6" + resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.6.tgz#8a58fe78f00dcd70c370451759dfbfaf03e8ee9f" + integrity sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA== + dependencies: + path-key "^3.1.0" + shebang-command "^2.0.0" + which "^2.0.1" -cross-spawn@^6.0.0, cross-spawn@^6.0.5: - version "6.0.5" - resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-6.0.5.tgz#4a5ec7c64dfae22c3a14124dbacdee846d80cbc4" - integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== +debug@^4.1.0, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2: + version "4.3.4" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" + integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: - nice-try "^1.0.4" - path-key "^2.0.1" - semver "^5.5.0" - shebang-command "^1.2.0" - which "^1.2.9" + ms "2.1.2" -cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0": - version "0.3.2" - resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.2.tgz#b8036170c79f07a90ff2f16e22284027a243848b" - integrity sha1-uANhcMefB6kP8vFuIihAJ6JDhIs= +dedent@^1.0.0: + version "1.5.1" + resolved "https://registry.yarnpkg.com/dedent/-/dedent-1.5.1.tgz#4f3fc94c8b711e9bb2800d185cd6ad20f2a90aff" + integrity sha512-+LxW+KLWxu3HW3M2w2ympwtqPrqYRzU8fqi6Fhd18fBALe15blJPI/I4+UHveMVG6lJqB4JNd4UG0S5cnVHwIg== -"cssstyle@>= 0.3.1 < 0.4.0": - version "0.3.1" - resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.3.1.tgz#6da9b4cff1bc5d716e6e5fe8e04fcb1b50a49adf" - integrity sha512-tNvaxM5blOnxanyxI6panOsnfiyLRj3HV4qjqqS45WPNS1usdYWRUQjqTEEELK73lpeP/1KoIGYUwrBn/VcECA== - dependencies: - cssom "0.3.x" +deep-is@^0.1.3: + version "0.1.4" + resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.4.tgz#a6f2dce612fadd2ef1f519b73551f17e85199831" + integrity sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ== -dashdash@^1.12.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" - integrity sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA= - dependencies: - assert-plus "^1.0.0" +deepmerge@^4.2.2: + version "4.3.1" + resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" + integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== -data-urls@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/data-urls/-/data-urls-1.0.0.tgz#24802de4e81c298ea8a9388bb0d8e461c774684f" - integrity sha512-ai40PPQR0Fn1lD2PPie79CibnlMN2AYiDhwFX/rZHVsxbs5kNJSjegqXIprhouGXlRdEnfybva7kqRGnB6mypA== +detect-newline@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-3.1.0.tgz#576f5dfc63ae1a192ff192d8ad3af6308991b651" + integrity sha512-TLz+x/vEXm/Y7P7wn1EJFNLxYpUD4TgMosxY6fAVJUnJMbupHBOncxyWUG9OpTaH9EBD7uFI5LfEgmMOc54DsA== + +diff-sequences@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-29.6.3.tgz#4deaf894d11407c51efc8418012f9e70b84ea921" + integrity sha512-EjePK1srD3P08o2j4f0ExnylqRs5B9tJjcp9t1krH2qRi8CCdsYfwe9JgSLurFBWwq4uOlipzfk5fHNvwFKr8Q== + +electron-to-chromium@^1.4.535: + version "1.4.588" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.4.588.tgz#d553f3c008e73488fb181fdf2601fdb0b1ffbb78" + integrity sha512-soytjxwbgcCu7nh5Pf4S2/4wa6UIu+A3p03U2yVr53qGxi1/VTR3ENI+p50v+UxqqZAfl48j3z55ud7VHIOr9w== + +emittery@^0.13.1: + version "0.13.1" + resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.13.1.tgz#c04b8c3457490e0847ae51fced3af52d338e3dad" + integrity sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ== + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +error-ex@^1.3.1: + version "1.3.2" + resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" + integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== dependencies: - abab "^1.0.4" - whatwg-mimetype "^2.0.0" - whatwg-url "^6.4.0" + is-arrayish "^0.2.1" -debug@^2.2.0, debug@^2.3.3, debug@^2.6.8, debug@^2.6.9: - version "2.6.9" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== - dependencies: - ms "2.0.0" +escalade@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40" + integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== -debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" - integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== - dependencies: - ms "^2.1.1" +escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" + integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== -decamelize@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" - integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= +escape-string-regexp@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-2.0.0.tgz#a30304e99daa32e23b2fd20f51babd07cffca344" + integrity sha512-UpzcLCXolUWcNu5HtVMHYdXJjArjsF9C0aNnquZYY4uW/Vu0miy5YoWvbV345HauVvcAUnpRuhMMcqTcGOY2+w== -decode-uri-component@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545" - integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= +escape-string-regexp@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz#14ba83a5d373e3d311e5afca29cf5bfad965bf34" + integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -deep-is@~0.1.3: - version "0.1.3" - resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.3.tgz#b369d6fb5dbc13eecf524f91b070feedc357cf34" - integrity sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ= +eslint-config-prettier@^10.0.2: + version "10.0.2" + resolved "https://registry.yarnpkg.com/eslint-config-prettier/-/eslint-config-prettier-10.0.2.tgz#47444de8aa104ce82c2f91ad2a5e96b62c01e20d" + integrity sha512-1105/17ZIMjmCOJOPNfVdbXafLCLj3hPmkmB7dLgt7XsQ/zkxSuDerE/xgO3RxoHysR1N1whmquY0lSn2O0VLg== -default-require-extensions@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/default-require-extensions/-/default-require-extensions-2.0.0.tgz#f5f8fbb18a7d6d50b21f641f649ebb522cfe24f7" - integrity sha1-9fj7sYp9bVCyH2QfZJ67Uiz+JPc= +eslint-scope@^8.2.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-8.2.0.tgz#377aa6f1cb5dc7592cfd0b7f892fd0cf352ce442" + integrity sha512-PHlWUfG6lvPc3yvP5A4PNyBL1W8fkDUccmI21JUu/+GKZBoH/W5u6usENXUrWFRsyoW5ACUjFGgAFQp5gUlb/A== dependencies: - strip-bom "^3.0.0" + esrecurse "^4.3.0" + estraverse "^5.2.0" -define-properties@^1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.2.tgz#83a73f2fea569898fb737193c8f873caf6d45c94" - integrity sha1-g6c/L+pWmJj7c3GTyPhzyvbUXJQ= - dependencies: - foreach "^2.0.5" - object-keys "^1.0.8" +eslint-visitor-keys@^3.3.0: + version "3.4.3" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz#0cd72fe8550e3c2eae156a96a4dddcd1c8ac5800" + integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag== -define-properties@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.1.3.tgz#cf88da6cbee26fe6db7094f61d870cbd84cee9f1" - integrity sha512-3MqfYKj2lLzdMSf8ZIZE/V+Zuy+BgD6f164e8K2w7dgnpKArBDerGYpM46IYYcjnkdPNMjPk9A6VFB8+3SKlXQ== +eslint-visitor-keys@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-4.0.0.tgz#e3adc021aa038a2a8e0b2f8b0ce8f66b9483b1fb" + integrity sha512-OtIRv/2GyiF6o/d8K7MYKKbXrOUBIK6SfkIRM4Z0dY3w+LiQ0vy3F57m0Z71bjbyeiWFiHJ8brqnmE6H6/jEuw== + +eslint-visitor-keys@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-4.2.0.tgz#687bacb2af884fcdda8a6e7d65c606f46a14cd45" + integrity sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw== + +eslint@^9.21.0: + version "9.21.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-9.21.0.tgz#b1c9c16f5153ff219791f627b94ab8f11f811591" + integrity sha512-KjeihdFqTPhOMXTt7StsDxriV4n66ueuF/jfPNC3j/lduHwr/ijDwJMsF+wyMJethgiKi5wniIE243vi07d3pg== + dependencies: + "@eslint-community/eslint-utils" "^4.2.0" + "@eslint-community/regexpp" "^4.12.1" + "@eslint/config-array" "^0.19.2" + "@eslint/core" "^0.12.0" + "@eslint/eslintrc" "^3.3.0" + "@eslint/js" "9.21.0" + "@eslint/plugin-kit" "^0.2.7" + "@humanfs/node" "^0.16.6" + "@humanwhocodes/module-importer" "^1.0.1" + "@humanwhocodes/retry" "^0.4.2" + "@types/estree" "^1.0.6" + "@types/json-schema" "^7.0.15" + ajv "^6.12.4" + chalk "^4.0.0" + cross-spawn "^7.0.6" + debug "^4.3.2" + escape-string-regexp "^4.0.0" + eslint-scope "^8.2.0" + eslint-visitor-keys "^4.2.0" + espree "^10.3.0" + esquery "^1.5.0" + esutils "^2.0.2" + fast-deep-equal "^3.1.3" + file-entry-cache "^8.0.0" + find-up "^5.0.0" + glob-parent "^6.0.2" + ignore "^5.2.0" + imurmurhash "^0.1.4" + is-glob "^4.0.0" + json-stable-stringify-without-jsonify "^1.0.1" + lodash.merge "^4.6.2" + minimatch "^3.1.2" + natural-compare "^1.4.0" + optionator "^0.9.3" + +espree@^10.0.1: + version "10.0.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-10.0.1.tgz#600e60404157412751ba4a6f3a2ee1a42433139f" + integrity sha512-MWkrWZbJsL2UwnjxTX3gG8FneachS/Mwg7tdGXce011sJd5b0JG54vat5KHnfSBODZ3Wvzd2WnjxyzsRoVv+ww== dependencies: - object-keys "^1.0.12" + acorn "^8.11.3" + acorn-jsx "^5.3.2" + eslint-visitor-keys "^4.0.0" -define-property@^0.2.5: - version "0.2.5" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-0.2.5.tgz#c35b1ef918ec3c990f9a5bc57be04aacec5c8116" - integrity sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY= +espree@^10.3.0: + version "10.3.0" + resolved "https://registry.yarnpkg.com/espree/-/espree-10.3.0.tgz#29267cf5b0cb98735b65e64ba07e0ed49d1eed8a" + integrity sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg== dependencies: - is-descriptor "^0.1.0" + acorn "^8.14.0" + acorn-jsx "^5.3.2" + eslint-visitor-keys "^4.2.0" -define-property@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-1.0.0.tgz#769ebaaf3f4a63aad3af9e8d304c9bbe79bfb0e6" - integrity sha1-dp66rz9KY6rTr56NMEybvnm/sOY= +esprima@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" + integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== + +esquery@^1.5.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.6.0.tgz#91419234f804d852a82dceec3e16cdc22cf9dae7" + integrity sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg== dependencies: - is-descriptor "^1.0.0" + estraverse "^5.1.0" -define-property@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/define-property/-/define-property-2.0.2.tgz#d459689e8d654ba77e02a817f8710d702cb16e9d" - integrity sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ== +esrecurse@^4.3.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.3.0.tgz#7ad7964d679abb28bee72cec63758b1c5d2c9921" + integrity sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag== dependencies: - is-descriptor "^1.0.2" - isobject "^3.0.1" + estraverse "^5.2.0" -delayed-stream@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - integrity sha1-3zrhmayt+31ECqrgsp4icrJOxhk= - -detect-newline@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2" - integrity sha1-9B8cEL5LAOh7XxPaaAdZ8sW/0+I= - -diff-sequences@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-24.3.0.tgz#0f20e8a1df1abddaf4d9c226680952e64118b975" - integrity sha512-xLqpez+Zj9GKSnPWS0WZw1igGocZ+uua8+y+5dDNTT934N3QuY1sp2LkHzwiaYQGz60hMq0pjAshdeXm5VUOEw== - -dir-glob@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/dir-glob/-/dir-glob-2.0.0.tgz#0b205d2b6aef98238ca286598a8204d29d0a0034" - integrity sha512-37qirFDz8cA5fimp9feo43fSuRo2gHwaIn6dXL8Ber1dGwUosDrGZeCCXq57WnIqE4aQ+u3eQZzsk1yOzhdwag== - dependencies: - arrify "^1.0.1" - path-type "^3.0.0" - -doctrine@1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-1.5.0.tgz#379dce730f6166f76cefa4e6707a159b02c5a6fa" - integrity sha1-N53Ocw9hZvds76TmcHoVmwLFpvo= - dependencies: - esutils "^2.0.2" - isarray "^1.0.0" - -doctrine@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-3.0.0.tgz#addebead72a6574db783639dc87a121773973961" - integrity sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w== - dependencies: - esutils "^2.0.2" - -domexception@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/domexception/-/domexception-1.0.1.tgz#937442644ca6a31261ef36e3ec677fe805582c90" - integrity sha512-raigMkn7CJNNo6Ihro1fzG7wr3fHuYVytzquZKX5n0yizGsTcYgzdIUwj1X9pK0VvjeihV+XiclP+DjwbsSKug== - dependencies: - webidl-conversions "^4.0.2" - -ecc-jsbn@~0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505" - integrity sha1-D8c6ntXw1Tw4GTOYUj735UN3dQU= - dependencies: - jsbn "~0.1.0" - -emoji-regex@^7.0.1: - version "7.0.3" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" - integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== - -end-of-stream@^1.1.0: - version "1.4.1" - resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.1.tgz#ed29634d19baba463b6ce6b80a37213eab71ec43" - integrity sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q== - dependencies: - once "^1.4.0" - -error-ex@^1.2.0, error-ex@^1.3.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== - dependencies: - is-arrayish "^0.2.1" - -es-abstract@^1.12.0: - version "1.13.0" - resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.13.0.tgz#ac86145fdd5099d8dd49558ccba2eaf9b88e24e9" - integrity sha512-vDZfg/ykNxQVwup/8E1BZhVzFfBxs9NqMzGcvIJrqg5k2/5Za2bWo40dK2J1pgLngZ7c+Shh8lwYtLGyrwPutg== - dependencies: - es-to-primitive "^1.2.0" - function-bind "^1.1.1" - has "^1.0.3" - is-callable "^1.1.4" - is-regex "^1.0.4" - object-keys "^1.0.12" - -es-abstract@^1.5.1: - version "1.11.0" - resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.11.0.tgz#cce87d518f0496893b1a30cd8461835535480681" - integrity sha512-ZnQrE/lXTTQ39ulXZ+J1DTFazV9qBy61x2bY071B+qGco8Z8q1QddsLdt/EF8Ai9hcWH72dWS0kFqXLxOxqslA== - dependencies: - es-to-primitive "^1.1.1" - function-bind "^1.1.1" - has "^1.0.1" - is-callable "^1.1.3" - is-regex "^1.0.4" - -es-to-primitive@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.1.1.tgz#45355248a88979034b6792e19bb81f2b7975dd0d" - integrity sha1-RTVSSKiJeQNLZ5Lhm7gfK3l13Q0= - dependencies: - is-callable "^1.1.1" - is-date-object "^1.0.1" - is-symbol "^1.0.1" - -es-to-primitive@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.0.tgz#edf72478033456e8dda8ef09e00ad9650707f377" - integrity sha512-qZryBOJjV//LaxLTV6UC//WewneB3LcXOL9NP++ozKVXsIIIpm/2c13UDiD9Jp2eThsecw9m3jPqDwTyobcdbg== - dependencies: - is-callable "^1.1.4" - is-date-object "^1.0.1" - is-symbol "^1.0.2" - -escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= - -escodegen@1.11.0: - version "1.11.0" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.11.0.tgz#b27a9389481d5bfd5bec76f7bb1eb3f8f4556589" - integrity sha512-IeMV45ReixHS53K/OmfKAIztN/igDHzTJUhZM3k1jMhIZWjk45SMwAtBsEXiJp3vSPmTcu6CXn7mDvFHRN66fw== - dependencies: - esprima "^3.1.3" - estraverse "^4.2.0" - esutils "^2.0.2" - optionator "^0.8.1" - optionalDependencies: - source-map "~0.6.1" - -escodegen@^1.9.0: - version "1.9.1" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.9.1.tgz#dbae17ef96c8e4bedb1356f4504fa4cc2f7cb7e2" - integrity sha512-6hTjO1NAWkHnDk3OqQ4YrCuwwmGHL9S3nPlzBOUG/R44rda3wLNrfvQ5fkSGjyhHFKM7ALPKcKGrwvCLe0lC7Q== - dependencies: - esprima "^3.1.3" - estraverse "^4.2.0" - esutils "^2.0.2" - optionator "^0.8.1" - optionalDependencies: - source-map "~0.6.1" - -eslint-config-airbnb-base@^13.1.0: - version "13.1.0" - resolved "https://registry.yarnpkg.com/eslint-config-airbnb-base/-/eslint-config-airbnb-base-13.1.0.tgz#b5a1b480b80dfad16433d6c4ad84e6605052c05c" - integrity sha512-XWwQtf3U3zIoKO1BbHh6aUhJZQweOwSt4c2JrPDg9FP3Ltv3+YfEv7jIDB8275tVnO/qOHbfuYg3kzw6Je7uWw== - dependencies: - eslint-restricted-globals "^0.1.1" - object.assign "^4.1.0" - object.entries "^1.0.4" - -eslint-import-resolver-node@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz#58f15fb839b8d0576ca980413476aab2472db66a" - integrity sha512-sfmTqJfPSizWu4aymbPr4Iidp5yKm8yDkHp+Ir3YiTHiiDfxh69mOUsmiqW6RZ9zRXFaF64GtYmN7e+8GHBv6Q== - dependencies: - debug "^2.6.9" - resolve "^1.5.0" - -eslint-module-utils@^2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.3.0.tgz#546178dab5e046c8b562bbb50705e2456d7bda49" - integrity sha512-lmDJgeOOjk8hObTysjqH7wyMi+nsHwwvfBykwfhjR1LNdd7C2uFJBvx4OpWYpXOw4df1yE1cDEVd1yLHitk34w== - dependencies: - debug "^2.6.8" - pkg-dir "^2.0.0" - -eslint-plugin-import@^2.16.0: - version "2.16.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.16.0.tgz#97ac3e75d0791c4fac0e15ef388510217be7f66f" - integrity sha512-z6oqWlf1x5GkHIFgrSvtmudnqM6Q60KM4KvpWi5ubonMjycLjndvd5+8VAZIsTlHC03djdgJuyKG6XO577px6A== - dependencies: - contains-path "^0.1.0" - debug "^2.6.9" - doctrine "1.5.0" - eslint-import-resolver-node "^0.3.2" - eslint-module-utils "^2.3.0" - has "^1.0.3" - lodash "^4.17.11" - minimatch "^3.0.4" - read-pkg-up "^2.0.0" - resolve "^1.9.0" - -eslint-restricted-globals@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/eslint-restricted-globals/-/eslint-restricted-globals-0.1.1.tgz#35f0d5cbc64c2e3ed62e93b4b1a7af05ba7ed4d7" - integrity sha1-NfDVy8ZMLj7WLpO0saevBbp+1Nc= - -eslint-scope@^4.0.3: - version "4.0.3" - resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848" - integrity sha512-p7VutNr1O/QrxysMo3E45FjYDTeXBy0iTltPFNSqKAIfjDSXC+4dj+qfyuD8bfAXrW/y6lW3O76VaYNPKfpKrg== - dependencies: - esrecurse "^4.1.0" - estraverse "^4.1.1" - -eslint-utils@^1.3.1: - version "1.3.1" - resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.3.1.tgz#9a851ba89ee7c460346f97cf8939c7298827e512" - integrity sha512-Z7YjnIldX+2XMcjr7ZkgEsOj/bREONV60qYeB/bjMAqqqZ4zxKyWX+BOUkdmRmA9riiIPVvo5x86m5elviOk0Q== - -eslint-visitor-keys@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-1.0.0.tgz#3f3180fb2e291017716acb4c9d6d5b5c34a6a81d" - integrity sha512-qzm/XxIbxm/FHyH341ZrbnMUpe+5Bocte9xkmFMzPMjRaZMcXww+MpBptFvtU+79L362nqiLhekCxCxDPaUMBQ== - -eslint@^5.15.0: - version "5.15.3" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-5.15.3.tgz#c79c3909dc8a7fa3714fb340c11e30fd2526b8b5" - integrity sha512-vMGi0PjCHSokZxE0NLp2VneGw5sio7SSiDNgIUn2tC0XkWJRNOIoHIg3CliLVfXnJsiHxGAYrkw0PieAu8+KYQ== - dependencies: - "@babel/code-frame" "^7.0.0" - ajv "^6.9.1" - chalk "^2.1.0" - cross-spawn "^6.0.5" - debug "^4.0.1" - doctrine "^3.0.0" - eslint-scope "^4.0.3" - eslint-utils "^1.3.1" - eslint-visitor-keys "^1.0.0" - espree "^5.0.1" - esquery "^1.0.1" - esutils "^2.0.2" - file-entry-cache "^5.0.1" - functional-red-black-tree "^1.0.1" - glob "^7.1.2" - globals "^11.7.0" - ignore "^4.0.6" - import-fresh "^3.0.0" - imurmurhash "^0.1.4" - inquirer "^6.2.2" - js-yaml "^3.12.0" - json-stable-stringify-without-jsonify "^1.0.1" - levn "^0.3.0" - lodash "^4.17.11" - minimatch "^3.0.4" - mkdirp "^0.5.1" - natural-compare "^1.4.0" - optionator "^0.8.2" - path-is-inside "^1.0.2" - progress "^2.0.0" - regexpp "^2.0.1" - semver "^5.5.1" - strip-ansi "^4.0.0" - strip-json-comments "^2.0.1" - table "^5.2.3" - text-table "^0.2.0" - -espree@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/espree/-/espree-5.0.1.tgz#5d6526fa4fc7f0788a5cf75b15f30323e2f81f7a" - integrity sha512-qWAZcWh4XE/RwzLJejfcofscgMc9CamR6Tn1+XRXNzrvUSSbiAjGOI/fggztjIi7y9VLPqnICMIPiGyr8JaZ0A== - dependencies: - acorn "^6.0.7" - acorn-jsx "^5.0.0" - eslint-visitor-keys "^1.0.0" - -esprima@^3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" - integrity sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM= - -esprima@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804" - integrity sha512-oftTcaMu/EGrEIu904mWteKIv8vMuOgGYo7EhVJJN00R/EED9DCua/xxHRdYnKtcECzVg7xOWhflvJMnqcFZjw== - -esquery@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== - dependencies: - estraverse "^4.0.0" - -esrecurse@^4.1.0: - version "4.2.1" - resolved "https://registry.yarnpkg.com/esrecurse/-/esrecurse-4.2.1.tgz#007a3b9fdbc2b3bb87e4879ea19c92fdbd3942cf" - integrity sha512-64RBB++fIOAXPw3P9cy89qfMlvZEXZkqqJkjqqXIvzP5ezRZjW+lPWjw35UX/3EhUPFYbg5ER4JYgDw4007/DQ== - dependencies: - estraverse "^4.1.0" - -estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.2.0.tgz#0dee3fed31fcd469618ce7342099fc1afa0bdb13" - integrity sha1-De4/7TH81GlhjOc0IJn8GvoL2xM= +estraverse@^5.1.0, estraverse@^5.2.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.3.0.tgz#2eea5290702f26ab8fe5370370ff86c965d21123" + integrity sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA== esutils@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.2.tgz#0abf4f1caa5bcb1f7a9d8acc6dea4faaa04bac9b" - integrity sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs= - -exec-sh@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.3.2.tgz#6738de2eb7c8e671d0366aea0b0db8c6f7d7391b" - integrity sha512-9sLAvzhI5nc8TpuQUh4ahMdCrWT00wPWz7j47/emR5+2qEfoZP5zzUXvx+vdx+H6ohhnsYC31iX04QLYJK8zTg== - -execa@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8" - integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== - dependencies: - cross-spawn "^6.0.0" - get-stream "^4.0.0" - is-stream "^1.1.0" - npm-run-path "^2.0.0" - p-finally "^1.0.0" - signal-exit "^3.0.0" - strip-eof "^1.0.0" + version "2.0.3" + resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" + integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== + +execa@^5.0.0: + version "5.1.1" + resolved "https://registry.yarnpkg.com/execa/-/execa-5.1.1.tgz#f80ad9cbf4298f7bd1d4c9555c21e93741c411dd" + integrity sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg== + dependencies: + cross-spawn "^7.0.3" + get-stream "^6.0.0" + human-signals "^2.1.0" + is-stream "^2.0.0" + merge-stream "^2.0.0" + npm-run-path "^4.0.1" + onetime "^5.1.2" + signal-exit "^3.0.3" + strip-final-newline "^2.0.0" exit@^0.1.2: version "0.1.2" resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c" - integrity sha1-BjJjj42HfMghB9MKD/8aF8uhzQw= - -expand-brackets@^2.1.4: - version "2.1.4" - resolved "https://registry.yarnpkg.com/expand-brackets/-/expand-brackets-2.1.4.tgz#b77735e315ce30f6b6eff0f83b04151a22449622" - integrity sha1-t3c14xXOMPa27/D4OwQVGiJEliI= - dependencies: - debug "^2.3.3" - define-property "^0.2.5" - extend-shallow "^2.0.1" - posix-character-classes "^0.1.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -expand-template@~1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/expand-template/-/expand-template-1.1.1.tgz#981f188c0c3a87d2e28f559bc541426ff94f21dd" - integrity sha512-cebqLtV8KOZfw0UI8TEFWxtczxxC1jvyUvx6H4fyp1K1FN7A4Q+uggVUlOsI1K8AGU0rwOGqP8nCapdrw8CYQg== - -expect@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/expect/-/expect-24.5.0.tgz#492fb0df8378d8474cc84b827776b069f46294ed" - integrity sha512-p2Gmc0CLxOgkyA93ySWmHFYHUPFIHG6XZ06l7WArWAsrqYVaVEkOU5NtT5i68KUyGKbkQgDCkiT65bWmdoL6Bw== - dependencies: - "@jest/types" "^24.5.0" - ansi-styles "^3.2.0" - jest-get-type "^24.3.0" - jest-matcher-utils "^24.5.0" - jest-message-util "^24.5.0" - jest-regex-util "^24.3.0" - -extend-shallow@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" - integrity sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8= - dependencies: - is-extendable "^0.1.0" - -extend-shallow@^3.0.0, extend-shallow@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-3.0.2.tgz#26a71aaf073b39fb2127172746131c2704028db8" - integrity sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg= - dependencies: - assign-symbols "^1.0.0" - is-extendable "^1.0.1" + integrity sha512-Zk/eNKV2zbjpKzrsQ+n1G6poVbErQxJ0LBOJXaKZ1EViLzH+hrLu9cdXI4zw9dBQJslwBEpbQ2P1oS7nDxs6jQ== -extend@~3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" - integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== - -external-editor@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.0.3.tgz#5866db29a97826dbe4bf3afd24070ead9ea43a27" - integrity sha512-bn71H9+qWoOQKyZDo25mOMVpSmXROAsTJVVVYzrrtol3d4y+AsKjf4Iwl2Q+IuT0kFSQ1qo166UuIwqYq7mGnA== +expect@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/expect/-/expect-29.7.0.tgz#578874590dcb3214514084c08115d8aee61e11bc" + integrity sha512-2Zks0hf1VLFYI1kbh0I5jP3KHHyCHpkfyHBzsSXRFgl/Bg9mWYfMW8oD+PdMPlEwy5HNsR9JutYy6pMeOh61nw== dependencies: - chardet "^0.7.0" - iconv-lite "^0.4.24" - tmp "^0.0.33" - -extglob@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/extglob/-/extglob-2.0.4.tgz#ad00fe4dc612a9232e8718711dc5cb5ab0285543" - integrity sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw== - dependencies: - array-unique "^0.3.2" - define-property "^1.0.0" - expand-brackets "^2.1.4" - extend-shallow "^2.0.1" - fragment-cache "^0.2.1" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -extsprintf@1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" - integrity sha1-lpGEQOMEGnpBT4xS48V06zw+HgU= - -extsprintf@^1.2.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" - integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= - -fast-deep-equal@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" - integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= + "@jest/expect-utils" "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" -fast-glob@^2.0.2: - version "2.2.6" - resolved "https://registry.yarnpkg.com/fast-glob/-/fast-glob-2.2.6.tgz#a5d5b697ec8deda468d85a74035290a025a95295" - integrity sha512-0BvMaZc1k9F+MeWWMe8pL6YltFzZYcJsYU7D4JyDA6PAczaXvxqQQ/z+mDF7/4Mw01DeUc+i3CTKajnkANkV4w== - dependencies: - "@mrmlnc/readdir-enhanced" "^2.2.1" - "@nodelib/fs.stat" "^1.1.2" - glob-parent "^3.1.0" - is-glob "^4.0.0" - merge2 "^1.2.3" - micromatch "^3.1.10" +fast-deep-equal@^3.1.1, fast-deep-equal@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" + integrity sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q== -fast-json-stable-stringify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" - integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= +fast-json-stable-stringify@^2.0.0, fast-json-stable-stringify@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" + integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== -fast-levenshtein@~2.0.4: +fast-levenshtein@^2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" - integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= + integrity sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw== fb-watchman@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.0.tgz#54e9abf7dfa2f26cd9b1636c588c1afc05de5d58" - integrity sha1-VOmr99+i8mzZsWNsWIwa/AXeXVg= - dependencies: - bser "^2.0.0" - -figures@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-2.0.0.tgz#3ab1a2d2a62c8bfb431a0c94cb797a2fce27c962" - integrity sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI= - dependencies: - escape-string-regexp "^1.0.5" - -file-entry-cache@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" - integrity sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g== - dependencies: - flat-cache "^2.0.1" - -fileset@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/fileset/-/fileset-2.0.3.tgz#8e7548a96d3cc2327ee5e674168723a333bba2a0" - integrity sha1-jnVIqW08wjJ+5eZ0FocjozO7oqA= - dependencies: - glob "^7.0.3" - minimatch "^3.0.3" - -fill-range@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-4.0.0.tgz#d544811d428f98eb06a63dc402d2403c328c38f7" - integrity sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc= - dependencies: - extend-shallow "^2.0.1" - is-number "^3.0.0" - repeat-string "^1.6.1" - to-regex-range "^2.1.0" - -find-up@^2.0.0, find-up@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-2.1.0.tgz#45d1b7e506c717ddd482775a2b77920a3c0c57a7" - integrity sha1-RdG35QbHF93UgndaK3eSCjwMV6c= - dependencies: - locate-path "^2.0.0" - -find-up@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" - integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== + version "2.0.2" + resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.2.tgz#e9524ee6b5c77e9e5001af0f85f3adbb8623255c" + integrity sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA== dependencies: - locate-path "^3.0.0" + bser "2.1.1" -flat-cache@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-2.0.1.tgz#5d296d6f04bda44a4630a301413bdbc2ec085ec0" - integrity sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA== +file-entry-cache@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-8.0.0.tgz#7787bddcf1131bffb92636c69457bbc0edd6d81f" + integrity sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ== dependencies: - flatted "^2.0.0" - rimraf "2.6.3" - write "1.0.3" - -flatted@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.0.tgz#55122b6536ea496b4b44893ee2608141d10d9916" - integrity sha512-R+H8IZclI8AAkSBRQJLVOsxwAoHd6WC40b4QTNWIjzAa6BXOBfQcM587MXDTVPeYaopFNWHUFLx7eNmHDSxMWg== - -for-in@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80" - integrity sha1-gQaNKVqBQuwKxybG4iAMMPttXoA= - -foreach@^2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/foreach/-/foreach-2.0.5.tgz#0bee005018aeb260d0a3af3ae658dd0136ec1b99" - integrity sha1-C+4AUBiusmDQo6865ljdATbsG5k= - -forever-agent@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" - integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE= + flat-cache "^4.0.0" -form-data@~2.3.2: - version "2.3.3" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" - integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.6" - mime-types "^2.1.12" + to-regex-range "^5.0.1" -fragment-cache@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/fragment-cache/-/fragment-cache-0.2.1.tgz#4290fad27f13e89be7f33799c6bc5a0abfff0d19" - integrity sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk= +find-up@^4.0.0, find-up@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" + integrity sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw== dependencies: - map-cache "^0.2.2" + locate-path "^5.0.0" + path-exists "^4.0.0" -from2@^2.1.1: - version "2.3.0" - resolved "https://registry.yarnpkg.com/from2/-/from2-2.3.0.tgz#8bfb5502bde4a4d36cfdeea007fcca21d7e382af" - integrity sha1-i/tVAr3kpNNs/e6gB/zKIdfjgq8= +find-up@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-5.0.0.tgz#4c92819ecb7083561e4f4a240a86be5198f536fc" + integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== dependencies: - inherits "^2.0.1" - readable-stream "^2.0.0" + locate-path "^6.0.0" + path-exists "^4.0.0" -fs-extra@7.0.1: - version "7.0.1" - resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-7.0.1.tgz#4f189c44aa123b895f722804f55ea23eadc348e9" - integrity sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw== +flat-cache@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-4.0.1.tgz#0ece39fcb14ee012f4b0410bd33dd9c1f011127c" + integrity sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw== dependencies: - graceful-fs "^4.1.2" - jsonfile "^4.0.0" - universalify "^0.1.0" + flatted "^3.2.9" + keyv "^4.5.4" -fs-extra@~6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-6.0.1.tgz#8abc128f7946e310135ddc93b98bddb410e7a34b" - integrity sha512-GnyIkKhhzXZUWFCaJzvyDLEEgDkPfb4/TPvJCJVuS8MWZgoSsErf++QpiAlDnKFcqhRlm+tIOcencCjyJE6ZCA== - dependencies: - graceful-fs "^4.1.2" - jsonfile "^4.0.0" - universalify "^0.1.0" +flatted@^3.2.9: + version "3.2.9" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-3.2.9.tgz#7eb4c67ca1ba34232ca9d2d93e9886e611ad7daf" + integrity sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ== fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" - integrity sha1-FQStJSMVjKpA20onh8sBQRmU6k8= - -function-bind@^1.0.2, function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== -functional-red-black-tree@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" - integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= +fsevents@^2.3.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.3.3.tgz#cac6407785d03675a2a5e1a5305c697b347d90d6" + integrity sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw== -get-caller-file@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.2.tgz#f702e63127e7e231c160a80c1554acb70d5047e5" - integrity sha1-9wLmMSfn4jHBYKgMFVSstw1QR+U= +function-bind@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.2.tgz#2c02d864d97f3ea6c8830c464cbd11ab6eab7a1c" + integrity sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA== -get-caller-file@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.1.tgz#25835260d3a2b9665fcdbb08cb039a7bbf7011c0" - integrity sha512-SpOZHfz845AH0wJYVuZk2jWDqFmu7Xubsx+ldIpwzy5pDUpu7OJHK7QYNSA2NPlDSKQwM1GFaAkciOWjjW92Sg== +gensync@^1.0.0-beta.2: + version "1.0.0-beta.2" + resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.2.tgz#32a6ee76c3d7f52d46b2b1ae5d93fea8580a25e0" + integrity sha512-3hN7NaskYvMDLQY55gnW3NQ+mesEAepTqlg+VEbj7zzqEMBVNhzcGYYeqFo/TlYz6eQiFcp1HcsCZO+nGgS8zg== -get-stream@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-4.1.0.tgz#c1b255575f3dc21d59bfc79cd3d2b46b1c3a54b5" - integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== - dependencies: - pump "^3.0.0" +get-caller-file@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -get-value@^2.0.3, get-value@^2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28" - integrity sha1-3BXKHGcjh8p2vTesCjlbogQqLCg= +get-package-type@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" + integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== -getpass@^0.1.1: - version "0.1.7" - resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" - integrity sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo= - dependencies: - assert-plus "^1.0.0" +get-stream@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" + integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== -glob-parent@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-3.1.0.tgz#9e6af6299d8d3bd2bd40430832bd113df906c5ae" - integrity sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4= +glob-parent@^6.0.2: + version "6.0.2" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-6.0.2.tgz#6d237d99083950c79290f24c7642a3de9a28f9e3" + integrity sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A== dependencies: - is-glob "^3.1.0" - path-dirname "^1.0.0" - -glob-to-regexp@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.3.0.tgz#8c5a1494d2066c570cc3bfe4496175acc4d502ab" - integrity sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs= + is-glob "^4.0.3" -glob@^7.0.3, glob@^7.0.5, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: - version "7.1.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" - integrity sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ== +glob@^7.1.3, glob@^7.1.4: + version "7.2.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== dependencies: fs.realpath "^1.0.0" inflight "^1.0.4" inherits "2" - minimatch "^3.0.4" + minimatch "^3.1.1" once "^1.3.0" path-is-absolute "^1.0.0" -globals@^11.1.0, globals@^11.7.0: - version "11.11.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.11.0.tgz#dcf93757fa2de5486fbeed7118538adf789e9c2e" - integrity sha512-WHq43gS+6ufNOEqlrDBxVEbb8ntfXrfAUU2ZOpCxrBdGKW3gyv8mCxAfIBD0DroPKGrJ2eSsXsLtY9MPntsyTw== - -globby@8.0.2: - version "8.0.2" - resolved "https://registry.yarnpkg.com/globby/-/globby-8.0.2.tgz#5697619ccd95c5275dbb2d6faa42087c1a941d8d" - integrity sha512-yTzMmKygLp8RUpG1Ymu2VXPSJQZjNAZPD4ywgYEaG7e4tBJeUQBO8OpXrf1RCNcEs5alsoJYPAMiIHP0cmeC7w== - dependencies: - array-union "^1.0.1" - dir-glob "2.0.0" - fast-glob "^2.0.2" - glob "^7.1.2" - ignore "^3.3.5" - pify "^3.0.0" - slash "^1.0.0" - -graceful-fs@^4.1.11, graceful-fs@^4.1.2: - version "4.1.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658" - integrity sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg= - -graceful-fs@^4.1.15, graceful-fs@^4.1.6: - version "4.1.15" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.15.tgz#ffb703e1066e8a0eeaa4c8b80ba9253eeefbfb00" - integrity sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA== - -growly@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" - integrity sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE= - -handlebars@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.0.tgz#0d6a6f34ff1f63cecec8423aa4169827bf787c3a" - integrity sha512-l2jRuU1NAWK6AW5qqcTATWQJvNPEwkM7NEKSiv/gqOsoSQbVoWyqVEY5GS+XPQ88zLNmqASRpzfdm8d79hJS+w== - dependencies: - async "^2.5.0" - optimist "^0.6.1" - source-map "^0.6.1" - optionalDependencies: - uglify-js "^3.1.4" +globals@^11.1.0: + version "11.12.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" + integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== -har-schema@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" - integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= +globals@^14.0.0: + version "14.0.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-14.0.0.tgz#898d7413c29babcf6bafe56fcadded858ada724e" + integrity sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ== -har-validator@~5.1.0: - version "5.1.3" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz#1ef89ebd3e4996557675eed9893110dc350fa080" - integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== - dependencies: - ajv "^6.5.5" - har-schema "^2.0.0" +globals@^16.0.0: + version "16.0.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-16.0.0.tgz#3d7684652c5c4fbd086ec82f9448214da49382d8" + integrity sha512-iInW14XItCXET01CQFqudPOWP2jYMl7T+QRQT+UNcR/iQncN/F0UNpgd76iFkBPgNQb4+X3LV9tLJYzwh+Gl3A== + +graceful-fs@^4.2.9: + version "4.2.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" - integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= - -has-symbols@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" - integrity sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q= - -has-value@^0.3.1: - version "0.3.1" - resolved "https://registry.yarnpkg.com/has-value/-/has-value-0.3.1.tgz#7b1f58bada62ca827ec0a2078025654845995e1f" - integrity sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8= - dependencies: - get-value "^2.0.3" - has-values "^0.1.4" - isobject "^2.0.0" - -has-value@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-value/-/has-value-1.0.0.tgz#18b281da585b1c5c51def24c930ed29a0be6b177" - integrity sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc= - dependencies: - get-value "^2.0.6" - has-values "^1.0.0" - isobject "^3.0.0" - -has-values@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/has-values/-/has-values-0.1.4.tgz#6d61de95d91dfca9b9a02089ad384bff8f62b771" - integrity sha1-bWHeldkd/Km5oCCJrThL/49it3E= - -has-values@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-values/-/has-values-1.0.0.tgz#95b0b63fec2146619a6fe57fe75628d5a39efe4f" - integrity sha1-lbC2P+whRmGab+V/51Yo1aOe/k8= - dependencies: - is-number "^3.0.0" - kind-of "^4.0.0" - -has@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.1.tgz#8461733f538b0837c9361e39a9ab9e9704dc2f28" - integrity sha1-hGFzP1OLCDfJNh45qauelwTcLyg= - dependencies: - function-bind "^1.0.2" - -has@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" - integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== - dependencies: - function-bind "^1.1.1" + integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== -hosted-git-info@^2.1.4: - version "2.6.0" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.6.0.tgz#23235b29ab230c576aab0d4f13fc046b0b038222" - integrity sha512-lIbgIIQA3lz5XaB6vxakj6sDHADJiZadYEJB+FgA+C4nubM1NwcuvUr9EJPmnH1skZqpqUzWborWo8EIUi0Sdw== +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== -html-encoding-sniffer@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz#e70d84b94da53aa375e11fe3a351be6642ca46f8" - integrity sha512-71lZziiDnsuabfdYiUeWdCVyKuqwWi23L8YeIgV9jSSZHCtb6wB1BKWooH7L3tn4/FuZJMVWyNaIDr4RGmaSYw== +hasown@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/hasown/-/hasown-2.0.0.tgz#f4c513d454a57b7c7e1650778de226b11700546c" + integrity sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA== dependencies: - whatwg-encoding "^1.0.1" + function-bind "^1.1.2" -http-signature@~1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" - integrity sha1-muzZJRFHcvPZW2WmCruPfBj7rOE= - dependencies: - assert-plus "^1.0.0" - jsprim "^1.2.2" - sshpk "^1.7.0" +html-escaper@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/html-escaper/-/html-escaper-2.0.2.tgz#dfd60027da36a36dfcbe236262c00a5822681453" + integrity sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg== -iconv-lite@0.4.19: - version "0.4.19" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b" - integrity sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ== +human-signals@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-2.1.0.tgz#dc91fcba42e4d06e4abaed33b3e7a3c02f514ea0" + integrity sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw== -iconv-lite@^0.4.24: - version "0.4.24" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" - integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== - dependencies: - safer-buffer ">= 2.1.2 < 3" +husky@^9.1.7: + version "9.1.7" + resolved "https://registry.yarnpkg.com/husky/-/husky-9.1.7.tgz#d46a38035d101b46a70456a850ff4201344c0b2d" + integrity sha512-5gs5ytaNjBrh5Ow3zrvdUUY+0VxIuWVL4i9irt6friV+BqdCfmV11CQTWMiBYWHbXhco+J1kHfTOUkePhCDvMA== -ignore@^3.3.5: - version "3.3.10" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" - integrity sha512-Pgs951kaMm5GXP7MOvxERINe3gsaVjUWFm+UZPSq9xYriQAksyhg0csnS0KXSNRD5NmNdapXEpjxG49+AKh/ug== +ignore@^5.2.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.0.tgz#67418ae40d34d6999c95ff56016759c718c82f78" + integrity sha512-g7dmpshy+gD7mh88OC9NwSGTKoc3kyLAZQRU1mt53Aw/vnvfXnbC+F/7F7QoYVKbV+KNvJx8wArewKy1vXMtlg== -ignore@^4.0.6: - version "4.0.6" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-4.0.6.tgz#750e3db5862087b4737ebac8207ffd1ef27b25fc" - integrity sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg== +ignore@^7.0.3: + version "7.0.3" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-7.0.3.tgz#397ef9315dfe0595671eefe8b633fec6943ab733" + integrity sha512-bAH5jbK/F3T3Jls4I0SO1hmPR0dKU0a7+SY6n1yzRtG54FLO8d6w/nxLFX2Nb7dBu6cCWXPaAME6cYqFUMmuCA== -import-fresh@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.0.0.tgz#a3d897f420cab0e671236897f75bc14b4885c390" - integrity sha512-pOnA9tfM3Uwics+SaBLCNyZZZbK+4PTu0OPZtLlMIrv17EdBoC15S9Kn8ckJ9TZTyKb3ywNE5y1yeDxxGA7nTQ== +import-fresh@^3.2.1: + version "3.3.0" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" + integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== dependencies: parent-module "^1.0.0" resolve-from "^4.0.0" -import-local@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/import-local/-/import-local-2.0.0.tgz#55070be38a5993cf18ef6db7e961f5bee5c5a09d" - integrity sha512-b6s04m3O+s3CGSbqDIyP4R6aAwAeYlVq9+WUWep6iHa8ETRf9yei1U48C5MmfJmV9AiLYYBKPMq/W+/WRpQmCQ== +import-local@^3.0.2: + version "3.1.0" + resolved "https://registry.yarnpkg.com/import-local/-/import-local-3.1.0.tgz#b4479df8a5fd44f6cdce24070675676063c95cb4" + integrity sha512-ASB07uLtnDs1o6EHjKpX34BKYDSqnFerfTOJL2HvMqF70LnxpjkzDB8J44oT9pu4AMPkQwf8jl6szgvNd2tRIg== dependencies: - pkg-dir "^3.0.0" - resolve-cwd "^2.0.0" + pkg-dir "^4.2.0" + resolve-cwd "^3.0.0" imurmurhash@^0.1.4: version "0.1.4" resolved "https://registry.yarnpkg.com/imurmurhash/-/imurmurhash-0.1.4.tgz#9218b9b2b928a238b13dc4fb6b6d576f231453ea" - integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= - -in-publish@~2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/in-publish/-/in-publish-2.0.0.tgz#e20ff5e3a2afc2690320b6dc552682a9c7fadf51" - integrity sha1-4g/146KvwmkDILbcVSaCqcf631E= + integrity sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA== inflight@^1.0.4: version "1.0.6" resolved "https://registry.yarnpkg.com/inflight/-/inflight-1.0.6.tgz#49bd6331d7d02d0c09bc910a1075ba8165b56df9" - integrity sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk= + integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== dependencies: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1, inherits@~2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de" - integrity sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4= - -inquirer@^6.2.1, inquirer@^6.2.2: - version "6.2.2" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.2.2.tgz#46941176f65c9eb20804627149b743a218f25406" - integrity sha512-Z2rREiXA6cHRR9KBOarR3WuLlFzlIfAEIiB45ll5SSadMg7WqOh1MKEjjndfuH5ewXdixWCxqnVfGOQzPeiztA== - dependencies: - ansi-escapes "^3.2.0" - chalk "^2.4.2" - cli-cursor "^2.1.0" - cli-width "^2.0.0" - external-editor "^3.0.3" - figures "^2.0.0" - lodash "^4.17.11" - mute-stream "0.0.7" - run-async "^2.2.0" - rxjs "^6.4.0" - string-width "^2.1.0" - strip-ansi "^5.0.0" - through "^2.3.6" - -into-stream@4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/into-stream/-/into-stream-4.0.0.tgz#ef10ee2ffb6f78af34c93194bbdc36c35f7d8a9d" - integrity sha512-i29KNyE5r0Y/UQzcQ0IbZO1MYJ53Jn0EcFRZPj5FzWKYH17kDFEOwuA+3jroymOI06SW1dEDnly9A1CAreC5dg== - dependencies: - from2 "^2.1.1" - p-is-promise "^2.0.0" - -invariant@^2.2.4: - version "2.2.4" - resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" - integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA== - dependencies: - loose-envify "^1.0.0" +inherits@2: + version "2.0.4" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -invert-kv@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz#7393f5afa59ec9ff5f67a27620d11c226e3eec02" - integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== +is-arrayish@^0.2.1: + version "0.2.1" + resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" + integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== -is-accessor-descriptor@^0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz#a9e12cb3ae8d876727eeef3843f8a0897b5c98d6" - integrity sha1-qeEss66Nh2cn7u84Q/igiXtcmNY= +is-core-module@^2.13.0: + version "2.13.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.13.1.tgz#ad0d7532c6fea9da1ebdc82742d74525c6273384" + integrity sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw== dependencies: - kind-of "^3.0.2" + hasown "^2.0.0" -is-accessor-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz#169c2f6d3df1f992618072365c9b0ea1f6878656" - integrity sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ== - dependencies: - kind-of "^6.0.0" +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" + integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== -is-arrayish@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0= +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== -is-buffer@^1.1.5: - version "1.1.6" - resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" - integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== +is-generator-fn@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.1.0.tgz#7d140adc389aaf3011a8f2a2a4cfa6faadffb118" + integrity sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ== -is-builtin-module@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-builtin-module/-/is-builtin-module-1.0.0.tgz#540572d34f7ac3119f8f76c30cbc1b1e037affbe" - integrity sha1-VAVy0096wxGfj3bDDLwbHgN6/74= +is-glob@^4.0.0, is-glob@^4.0.3: + version "4.0.3" + resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.3.tgz#64f61e42cbbb2eec2071a9dac0b28ba1e65d5084" + integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== dependencies: - builtin-modules "^1.0.0" + is-extglob "^2.1.1" -is-callable@^1.1.1, is-callable@^1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2" - integrity sha1-hut1OSgF3cM69xySoO7fdO52BLI= +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/is-number/-/is-number-7.0.0.tgz#7535345b896734d5f80c4d06c50955527a14f12b" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== -is-callable@^1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" - integrity sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA== +is-stream@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== -is-ci@^2.0.0: +isexe@^2.0.0: version "2.0.0" - resolved "https://registry.yarnpkg.com/is-ci/-/is-ci-2.0.0.tgz#6bc6334181810e04b5c22b3d589fdca55026404c" - integrity sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w== - dependencies: - ci-info "^2.0.0" + resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" + integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== -is-data-descriptor@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz#0b5ee648388e2c860282e793f1856fec3f301b56" - integrity sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y= +istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: + version "3.2.2" + resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.2.tgz#2d166c4b0644d43a39f04bf6c2edd1e585f31756" + integrity sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg== + +istanbul-lib-instrument@^5.0.4: + version "5.2.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-5.2.1.tgz#d10c8885c2125574e1c231cacadf955675e1ce3d" + integrity sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg== dependencies: - kind-of "^3.0.2" + "@babel/core" "^7.12.3" + "@babel/parser" "^7.14.7" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-coverage "^3.2.0" + semver "^6.3.0" -is-data-descriptor@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz#d84876321d0e7add03990406abbbbd36ba9268c7" - integrity sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ== +istanbul-lib-instrument@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-6.0.1.tgz#71e87707e8041428732518c6fb5211761753fbdf" + integrity sha512-EAMEJBsYuyyztxMxW3g7ugGPkrZsV57v0Hmv3mm1uQsmB+QnZuepg731CRaIgeUVSdmsTngOkSnauNF8p7FIhA== dependencies: - kind-of "^6.0.0" + "@babel/core" "^7.12.3" + "@babel/parser" "^7.14.7" + "@istanbuljs/schema" "^0.1.2" + istanbul-lib-coverage "^3.2.0" + semver "^7.5.4" -is-date-object@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" - integrity sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY= +istanbul-lib-report@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-3.0.1.tgz#908305bac9a5bd175ac6a74489eafd0fc2445a7d" + integrity sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw== + dependencies: + istanbul-lib-coverage "^3.0.0" + make-dir "^4.0.0" + supports-color "^7.1.0" -is-descriptor@^0.1.0: - version "0.1.6" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-0.1.6.tgz#366d8240dde487ca51823b1ab9f07a10a78251ca" - integrity sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg== +istanbul-lib-source-maps@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-4.0.1.tgz#895f3a709fcfba34c6de5a42939022f3e4358551" + integrity sha512-n3s8EwkdFIJCG3BPKBYvskgXGoy88ARzvegkitk60NxRdwltLOTaH7CUiMRXvwYorl0Q712iEjcWB+fK/MrWVw== dependencies: - is-accessor-descriptor "^0.1.6" - is-data-descriptor "^0.1.4" - kind-of "^5.0.0" + debug "^4.1.1" + istanbul-lib-coverage "^3.0.0" + source-map "^0.6.1" -is-descriptor@^1.0.0, is-descriptor@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-descriptor/-/is-descriptor-1.0.2.tgz#3b159746a66604b04f8c81524ba365c5f14d86ec" - integrity sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg== +istanbul-reports@^3.1.3: + version "3.1.6" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-3.1.6.tgz#2544bcab4768154281a2f0870471902704ccaa1a" + integrity sha512-TLgnMkKg3iTDsQ9PbPTdpfAK2DzjF9mqUG7RMgcQl8oFjad8ob4laGxv5XV5U9MAfx8D6tSJiUyuAwzLicaxlg== dependencies: - is-accessor-descriptor "^1.0.0" - is-data-descriptor "^1.0.0" - kind-of "^6.0.2" + html-escaper "^2.0.0" + istanbul-lib-report "^3.0.0" -is-extendable@^0.1.0, is-extendable@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89" - integrity sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik= +jest-changed-files@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-29.7.0.tgz#1c06d07e77c78e1585d020424dedc10d6e17ac3a" + integrity sha512-fEArFiwf1BpQ+4bXSprcDc3/x4HSzL4al2tozwVpDFpsxALjLYdyiIK4e5Vz66GQJIbXJ82+35PtysofptNX2w== + dependencies: + execa "^5.0.0" + jest-util "^29.7.0" + p-limit "^3.1.0" -is-extendable@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-1.0.1.tgz#a7470f9e426733d81bd81e1155264e3a3507cab4" - integrity sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA== - dependencies: - is-plain-object "^2.0.4" - -is-extglob@^2.1.0, is-extglob@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/is-extglob/-/is-extglob-2.1.1.tgz#a88c02535791f02ed37c76a1b9ea9773c833f8c2" - integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= - -is-fullwidth-code-point@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz#ef9e31386f031a7f0d643af82fde50c457ef00cb" - integrity sha1-754xOG8DGn8NZDr4L95QxFfvAMs= - dependencies: - number-is-nan "^1.0.0" - -is-fullwidth-code-point@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" - integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= - -is-generator-fn@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.0.0.tgz#038c31b774709641bda678b1f06a4e3227c10b3e" - integrity sha512-elzyIdM7iKoFHzcrndIqjYomImhxrFRnGP3galODoII4TB9gI7mZ+FnlLQmmjf27SxHS2gKEeyhX5/+YRS6H9g== - -is-glob@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-3.1.0.tgz#7ba5ae24217804ac70707b96922567486cc3e84a" - integrity sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo= - dependencies: - is-extglob "^2.1.0" - -is-glob@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.0.tgz#9521c76845cc2610a85203ddf080a958c2ffabc0" - integrity sha1-lSHHaEXMJhCoUgPd8ICpWML/q8A= - dependencies: - is-extglob "^2.1.1" - -is-number@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195" - integrity sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU= - dependencies: - kind-of "^3.0.2" - -is-number@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/is-number/-/is-number-4.0.0.tgz#0026e37f5454d73e356dfe6564699867c6a7f0ff" - integrity sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ== - -is-odd@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/is-odd/-/is-odd-2.0.0.tgz#7646624671fd7ea558ccd9a2795182f2958f1b24" - integrity sha512-OTiixgpZAT1M4NHgS5IguFp/Vz2VI3U7Goh4/HA1adtwyLtSBrxYlcSYkhpAE07s4fKEcjrFxyvtQBND4vFQyQ== +jest-circus@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-circus/-/jest-circus-29.7.0.tgz#b6817a45fcc835d8b16d5962d0c026473ee3668a" + integrity sha512-3E1nCMgipcTkCocFwM90XXQab9bS+GMsjdpmPrlelaxwD93Ad8iVEjX/vvHPdLPnFf+L40u+5+iutRdA1N9myw== dependencies: - is-number "^4.0.0" - -is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/is-plain-object/-/is-plain-object-2.0.4.tgz#2c163b3fafb1b606d9d17928f05c2a1c38e07677" - integrity sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og== - dependencies: - isobject "^3.0.1" - -is-promise@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" - integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= - -is-regex@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.4.tgz#5517489b547091b0930e095654ced25ee97e9491" - integrity sha1-VRdIm1RwkbCTDglWVM7SXul+lJE= - dependencies: - has "^1.0.1" - -is-stream@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44" - integrity sha1-EtSj3U5o4Lec6428hBc66A2RykQ= - -is-symbol@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.1.tgz#3cc59f00025194b6ab2e38dbae6689256b660572" - integrity sha1-PMWfAAJRlLarLjjbrmaJJWtmBXI= - -is-symbol@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.2.tgz#a055f6ae57192caee329e7a860118b497a950f38" - integrity sha512-HS8bZ9ox60yCJLH9snBpIwv9pYUAkcuLhSA1oero1UB5y9aiQpRA8y2ex945AOtCZL1lJDeIk3G5LthswI46Lw== - dependencies: - has-symbols "^1.0.0" - -is-typedarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" - integrity sha1-5HnICFjfDBsR3dppQPlgEfzaSpo= - -is-windows@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-windows/-/is-windows-1.0.2.tgz#d1850eb9791ecd18e6182ce12a30f396634bb19d" - integrity sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA== - -isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" - integrity sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE= - -isexe@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" - integrity sha1-6PvzdNxVb/iUehDcsFctYz8s+hA= - -isobject@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/isobject/-/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89" - integrity sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk= - dependencies: - isarray "1.0.0" - -isobject@^3.0.0, isobject@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/isobject/-/isobject-3.0.1.tgz#4e431e92b11a9731636aa1f9c8d1ccbcfdab78df" - integrity sha1-TkMekrEalzFjaqH5yNHMvP2reN8= - -isstream@~0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" - integrity sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo= - -istanbul-api@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/istanbul-api/-/istanbul-api-2.1.1.tgz#194b773f6d9cbc99a9258446848b0f988951c4d0" - integrity sha512-kVmYrehiwyeBAk/wE71tW6emzLiHGjYIiDrc8sfyty4F8M02/lrgXSm+R1kXysmF20zArvmZXjlE/mg24TVPJw== - dependencies: - async "^2.6.1" - compare-versions "^3.2.1" - fileset "^2.0.3" - istanbul-lib-coverage "^2.0.3" - istanbul-lib-hook "^2.0.3" - istanbul-lib-instrument "^3.1.0" - istanbul-lib-report "^2.0.4" - istanbul-lib-source-maps "^3.0.2" - istanbul-reports "^2.1.1" - js-yaml "^3.12.0" - make-dir "^1.3.0" - minimatch "^3.0.4" - once "^1.4.0" - -istanbul-lib-coverage@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#2aee0e073ad8c5f6a0b00e0dfbf52b4667472eda" - integrity sha512-nPvSZsVlbG9aLhZYaC3Oi1gT/tpyo3Yt5fNyf6NmcKIayz4VV/txxJFFKAK/gU4dcNn8ehsanBbVHVl0+amOLA== - -istanbul-lib-coverage@^2.0.2, istanbul-lib-coverage@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.3.tgz#0b891e5ad42312c2b9488554f603795f9a2211ba" - integrity sha512-dKWuzRGCs4G+67VfW9pBFFz2Jpi4vSp/k7zBcJ888ofV5Mi1g5CUML5GvMvV6u9Cjybftu+E8Cgp+k0dI1E5lw== - -istanbul-lib-hook@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/istanbul-lib-hook/-/istanbul-lib-hook-2.0.3.tgz#e0e581e461c611be5d0e5ef31c5f0109759916fb" - integrity sha512-CLmEqwEhuCYtGcpNVJjLV1DQyVnIqavMLFHV/DP+np/g3qvdxu3gsPqYoJMXm15sN84xOlckFB3VNvRbf5yEgA== - dependencies: - append-transform "^1.0.0" - -istanbul-lib-instrument@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.0.0.tgz#b5f066b2a161f75788be17a9d556f40a0cf2afc9" - integrity sha512-eQY9vN9elYjdgN9Iv6NS/00bptm02EBBk70lRMaVjeA6QYocQgenVrSgC28TJurdnZa80AGO3ASdFN+w/njGiQ== - dependencies: - "@babel/generator" "^7.0.0" - "@babel/parser" "^7.0.0" - "@babel/template" "^7.0.0" - "@babel/traverse" "^7.0.0" - "@babel/types" "^7.0.0" - istanbul-lib-coverage "^2.0.1" - semver "^5.5.0" - -istanbul-lib-instrument@^3.0.1, istanbul-lib-instrument@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/istanbul-lib-instrument/-/istanbul-lib-instrument-3.1.0.tgz#a2b5484a7d445f1f311e93190813fa56dfb62971" - integrity sha512-ooVllVGT38HIk8MxDj/OIHXSYvH+1tq/Vb38s8ixt9GoJadXska4WkGY+0wkmtYCZNYtaARniH/DixUGGLZ0uA== - dependencies: - "@babel/generator" "^7.0.0" - "@babel/parser" "^7.0.0" - "@babel/template" "^7.0.0" - "@babel/traverse" "^7.0.0" - "@babel/types" "^7.0.0" - istanbul-lib-coverage "^2.0.3" - semver "^5.5.0" - -istanbul-lib-report@^2.0.4: - version "2.0.4" - resolved "https://registry.yarnpkg.com/istanbul-lib-report/-/istanbul-lib-report-2.0.4.tgz#bfd324ee0c04f59119cb4f07dab157d09f24d7e4" - integrity sha512-sOiLZLAWpA0+3b5w5/dq0cjm2rrNdAfHWaGhmn7XEFW6X++IV9Ohn+pnELAl9K3rfpaeBfbmH9JU5sejacdLeA== - dependencies: - istanbul-lib-coverage "^2.0.3" - make-dir "^1.3.0" - supports-color "^6.0.0" - -istanbul-lib-source-maps@^3.0.1, istanbul-lib-source-maps@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/istanbul-lib-source-maps/-/istanbul-lib-source-maps-3.0.2.tgz#f1e817229a9146e8424a28e5d69ba220fda34156" - integrity sha512-JX4v0CiKTGp9fZPmoxpu9YEkPbEqCqBbO3403VabKjH+NRXo72HafD5UgnjTEqHL2SAjaZK1XDuDOkn6I5QVfQ== - dependencies: - debug "^4.1.1" - istanbul-lib-coverage "^2.0.3" - make-dir "^1.3.0" - rimraf "^2.6.2" - source-map "^0.6.1" - -istanbul-reports@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-2.1.1.tgz#72ef16b4ecb9a4a7bd0e2001e00f95d1eec8afa9" - integrity sha512-FzNahnidyEPBCI0HcufJoSEoKykesRlFcSzQqjH9x0+LC8tnnE/p/90PBLu8iZTxr8yYZNyTtiAujUqyN+CIxw== - dependencies: - handlebars "^4.1.0" - -jest-changed-files@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-24.5.0.tgz#4075269ee115d87194fd5822e642af22133cf705" - integrity sha512-Ikl29dosYnTsH9pYa1Tv9POkILBhN/TLZ37xbzgNsZ1D2+2n+8oEZS2yP1BrHn/T4Rs4Ggwwbp/x8CKOS5YJOg== - dependencies: - "@jest/types" "^24.5.0" - execa "^1.0.0" - throat "^4.0.0" - -jest-cli@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-24.5.0.tgz#598139d3446d1942fb7dc93944b9ba766d756d4b" - integrity sha512-P+Jp0SLO4KWN0cGlNtC7JV0dW1eSFR7eRpoOucP2UM0sqlzp/bVHeo71Omonvigrj9AvCKy7NtQANtqJ7FXz8g== - dependencies: - "@jest/core" "^24.5.0" - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" - chalk "^2.0.1" - exit "^0.1.2" - import-local "^2.0.0" - is-ci "^2.0.0" - jest-config "^24.5.0" - jest-util "^24.5.0" - jest-validate "^24.5.0" - prompts "^2.0.1" - realpath-native "^1.1.0" - yargs "^12.0.2" - -jest-config@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-24.5.0.tgz#404d1bc6bb81aed6bd1890d07e2dca9fbba2e121" - integrity sha512-t2UTh0Z2uZhGBNVseF8wA2DS2SuBiLOL6qpLq18+OZGfFUxTM7BzUVKyHFN/vuN+s/aslY1COW95j1Rw81huOQ== - dependencies: - "@babel/core" "^7.1.0" - "@jest/types" "^24.5.0" - babel-jest "^24.5.0" - chalk "^2.0.1" - glob "^7.1.1" - jest-environment-jsdom "^24.5.0" - jest-environment-node "^24.5.0" - jest-get-type "^24.3.0" - jest-jasmine2 "^24.5.0" - jest-regex-util "^24.3.0" - jest-resolve "^24.5.0" - jest-util "^24.5.0" - jest-validate "^24.5.0" - micromatch "^3.1.10" - pretty-format "^24.5.0" - realpath-native "^1.1.0" - -jest-diff@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.5.0.tgz#a2d8627964bb06a91893c0fbcb28ab228c257652" - integrity sha512-mCILZd9r7zqL9Uh6yNoXjwGQx0/J43OD2vvWVKwOEOLZliQOsojXwqboubAQ+Tszrb6DHGmNU7m4whGeB9YOqw== - dependencies: - chalk "^2.0.1" - diff-sequences "^24.3.0" - jest-get-type "^24.3.0" - pretty-format "^24.5.0" - -jest-docblock@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-24.3.0.tgz#b9c32dac70f72e4464520d2ba4aec02ab14db5dd" - integrity sha512-nlANmF9Yq1dufhFlKG9rasfQlrY7wINJbo3q01tu56Jv5eBU5jirylhF2O5ZBnLxzOVBGRDz/9NAwNyBtG4Nyg== - dependencies: - detect-newline "^2.1.0" - -jest-each@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-24.5.0.tgz#da14d017a1b7d0f01fb458d338314cafe7f72318" - integrity sha512-6gy3Kh37PwIT5sNvNY2VchtIFOOBh8UCYnBlxXMb5sr5wpJUDPTUATX2Axq1Vfk+HWTMpsYPeVYp4TXx5uqUBw== - dependencies: - "@jest/types" "^24.5.0" - chalk "^2.0.1" - jest-get-type "^24.3.0" - jest-util "^24.5.0" - pretty-format "^24.5.0" - -jest-environment-jsdom@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-24.5.0.tgz#1c3143063e1374100f8c2723a8b6aad23b6db7eb" - integrity sha512-62Ih5HbdAWcsqBx2ktUnor/mABBo1U111AvZWcLKeWN/n/gc5ZvDBKe4Og44fQdHKiXClrNGC6G0mBo6wrPeGQ== - dependencies: - "@jest/environment" "^24.5.0" - "@jest/fake-timers" "^24.5.0" - "@jest/types" "^24.5.0" - jest-mock "^24.5.0" - jest-util "^24.5.0" - jsdom "^11.5.1" - -jest-environment-node@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-24.5.0.tgz#763eebdf529f75b60aa600c6cf8cb09873caa6ab" - integrity sha512-du6FuyWr/GbKLsmAbzNF9mpr2Iu2zWSaq/BNHzX+vgOcts9f2ayXBweS7RAhr+6bLp6qRpMB6utAMF5Ygktxnw== - dependencies: - "@jest/environment" "^24.5.0" - "@jest/fake-timers" "^24.5.0" - "@jest/types" "^24.5.0" - jest-mock "^24.5.0" - jest-util "^24.5.0" - -jest-get-type@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.3.0.tgz#582cfd1a4f91b5cdad1d43d2932f816d543c65da" - integrity sha512-HYF6pry72YUlVcvUx3sEpMRwXEWGEPlJ0bSPVnB3b3n++j4phUEoSPcS6GC0pPJ9rpyPSe4cb5muFo6D39cXow== - -jest-haste-map@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.5.0.tgz#3f17d0c548b99c0c96ed2893f9c0ccecb2eb9066" - integrity sha512-mb4Yrcjw9vBgSvobDwH8QUovxApdimGcOkp+V1ucGGw4Uvr3VzZQBJhNm1UY3dXYm4XXyTW2G7IBEZ9pM2ggRQ== - dependencies: - "@jest/types" "^24.5.0" - fb-watchman "^2.0.0" - graceful-fs "^4.1.15" - invariant "^2.2.4" - jest-serializer "^24.4.0" - jest-util "^24.5.0" - jest-worker "^24.4.0" - micromatch "^3.1.10" - sane "^4.0.3" - -jest-jasmine2@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-24.5.0.tgz#e6af4d7f73dc527d007cca5a5b177c0bcc29d111" - integrity sha512-sfVrxVcx1rNUbBeyIyhkqZ4q+seNKyAG6iM0S2TYBdQsXjoFDdqWFfsUxb6uXSsbimbXX/NMkJIwUZ1uT9+/Aw== - dependencies: - "@babel/traverse" "^7.1.0" - "@jest/environment" "^24.5.0" - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" - chalk "^2.0.1" + "@jest/environment" "^29.7.0" + "@jest/expect" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" co "^4.6.0" - expect "^24.5.0" + dedent "^1.0.0" is-generator-fn "^2.0.0" - jest-each "^24.5.0" - jest-matcher-utils "^24.5.0" - jest-message-util "^24.5.0" - jest-runtime "^24.5.0" - jest-snapshot "^24.5.0" - jest-util "^24.5.0" - pretty-format "^24.5.0" - throat "^4.0.0" - -jest-leak-detector@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-24.5.0.tgz#21ae2b3b0da252c1171cd494f75696d65fb6fa89" - integrity sha512-LZKBjGovFRx3cRBkqmIg+BZnxbrLqhQl09IziMk3oeh1OV81Hg30RUIx885mq8qBv1PA0comB9bjKcuyNO1bCQ== - dependencies: - pretty-format "^24.5.0" - -jest-matcher-utils@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-24.5.0.tgz#5995549dcf09fa94406e89526e877b094dad8770" - integrity sha512-QM1nmLROjLj8GMGzg5VBra3I9hLpjMPtF1YqzQS3rvWn2ltGZLrGAO1KQ9zUCVi5aCvrkbS5Ndm2evIP9yZg1Q== - dependencies: - chalk "^2.0.1" - jest-diff "^24.5.0" - jest-get-type "^24.3.0" - pretty-format "^24.5.0" - -jest-message-util@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-24.5.0.tgz#181420a65a7ef2e8b5c2f8e14882c453c6d41d07" - integrity sha512-6ZYgdOojowCGiV0D8WdgctZEAe+EcFU+KrVds+0ZjvpZurUW2/oKJGltJ6FWY2joZwYXN5VL36GPV6pNVRqRnQ== - dependencies: - "@babel/code-frame" "^7.0.0" - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" - "@types/stack-utils" "^1.0.1" - chalk "^2.0.1" - micromatch "^3.1.10" - slash "^2.0.0" - stack-utils "^1.0.1" - -jest-mock@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-24.5.0.tgz#976912c99a93f2a1c67497a9414aa4d9da4c7b76" - integrity sha512-ZnAtkWrKf48eERgAOiUxVoFavVBziO2pAi2MfZ1+bGXVkDfxWLxU0//oJBkgwbsv6OAmuLBz4XFFqvCFMqnGUw== - dependencies: - "@jest/types" "^24.5.0" - -jest-pnp-resolver@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.1.tgz#ecdae604c077a7fbc70defb6d517c3c1c898923a" - integrity sha512-pgFw2tm54fzgYvc/OHrnysABEObZCUNFnhjoRjaVOCN8NYc032/gVjPaHD4Aq6ApkSieWtfKAFQtmDKAmhupnQ== - -jest-regex-util@^24.3.0: - version "24.3.0" - resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-24.3.0.tgz#d5a65f60be1ae3e310d5214a0307581995227b36" - integrity sha512-tXQR1NEOyGlfylyEjg1ImtScwMq8Oh3iJbGTjN7p0J23EuVX1MA8rwU69K4sLbCmwzgCUbVkm0FkSF9TdzOhtg== - -jest-resolve-dependencies@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-24.5.0.tgz#1a0dae9cdd41349ca4a84148b3e78da2ba33fd4b" - integrity sha512-dRVM1D+gWrFfrq2vlL5P9P/i8kB4BOYqYf3S7xczZ+A6PC3SgXYSErX/ScW/469pWMboM1uAhgLF+39nXlirCQ== - dependencies: - "@jest/types" "^24.5.0" - jest-regex-util "^24.3.0" - jest-snapshot "^24.5.0" - -jest-resolve@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-24.5.0.tgz#8c16ba08f60a1616c3b1cd7afb24574f50a24d04" - integrity sha512-ZIfGqLX1Rg8xJpQqNjdoO8MuxHV1q/i2OO1hLXjgCWFWs5bsedS8UrOdgjUqqNae6DXA+pCyRmdcB7lQEEbXew== - dependencies: - "@jest/types" "^24.5.0" - browser-resolve "^1.11.3" - chalk "^2.0.1" - jest-pnp-resolver "^1.2.1" - realpath-native "^1.1.0" - -jest-runner@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-24.5.0.tgz#9be26ece4fd4ab3dfb528b887523144b7c5ffca8" - integrity sha512-oqsiS9TkIZV5dVkD+GmbNfWBRPIvxqmlTQ+AQUJUQ07n+4xTSDc40r+aKBynHw9/tLzafC00DIbJjB2cOZdvMA== - dependencies: - "@jest/console" "^24.3.0" - "@jest/environment" "^24.5.0" - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" - chalk "^2.4.2" - exit "^0.1.2" - graceful-fs "^4.1.15" - jest-config "^24.5.0" - jest-docblock "^24.3.0" - jest-haste-map "^24.5.0" - jest-jasmine2 "^24.5.0" - jest-leak-detector "^24.5.0" - jest-message-util "^24.5.0" - jest-resolve "^24.5.0" - jest-runtime "^24.5.0" - jest-util "^24.5.0" - jest-worker "^24.4.0" - source-map-support "^0.5.6" - throat "^4.0.0" - -jest-runtime@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-24.5.0.tgz#3a76e0bfef4db3896d5116e9e518be47ba771aa2" - integrity sha512-GTFHzfLdwpaeoDPilNpBrorlPoNZuZrwKKzKJs09vWwHo+9TOsIIuszK8cWOuKC7ss07aN1922Ge8fsGdsqCuw== - dependencies: - "@jest/console" "^24.3.0" - "@jest/environment" "^24.5.0" - "@jest/source-map" "^24.3.0" - "@jest/transform" "^24.5.0" - "@jest/types" "^24.5.0" - "@types/yargs" "^12.0.2" - chalk "^2.0.1" + jest-each "^29.7.0" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-runtime "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + p-limit "^3.1.0" + pretty-format "^29.7.0" + pure-rand "^6.0.0" + slash "^3.0.0" + stack-utils "^2.0.3" + +jest-cli@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-29.7.0.tgz#5592c940798e0cae677eec169264f2d839a37995" + integrity sha512-OVVobw2IubN/GSYsxETi+gOe7Ka59EFMR/twOU3Jb2GnKKeMGJB5SGUUrEz3SFVmJASUdZUzy83sLNNQ2gZslg== + dependencies: + "@jest/core" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + chalk "^4.0.0" + create-jest "^29.7.0" exit "^0.1.2" + import-local "^3.0.2" + jest-config "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + yargs "^17.3.1" + +jest-config@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-29.7.0.tgz#bcbda8806dbcc01b1e316a46bb74085a84b0245f" + integrity sha512-uXbpfeQ7R6TZBqI3/TxCU4q4ttk3u0PJeC+E0zbfSoSjq6bJ7buBPxzQPL0ifrkY4DNu4JUdk0ImlBUYi840eQ== + dependencies: + "@babel/core" "^7.11.6" + "@jest/test-sequencer" "^29.7.0" + "@jest/types" "^29.6.3" + babel-jest "^29.7.0" + chalk "^4.0.0" + ci-info "^3.2.0" + deepmerge "^4.2.2" glob "^7.1.3" - graceful-fs "^4.1.15" - jest-config "^24.5.0" - jest-haste-map "^24.5.0" - jest-message-util "^24.5.0" - jest-mock "^24.5.0" - jest-regex-util "^24.3.0" - jest-resolve "^24.5.0" - jest-snapshot "^24.5.0" - jest-util "^24.5.0" - jest-validate "^24.5.0" - realpath-native "^1.1.0" - slash "^2.0.0" - strip-bom "^3.0.0" - yargs "^12.0.2" - -jest-serializer@^24.4.0: - version "24.4.0" - resolved "https://registry.yarnpkg.com/jest-serializer/-/jest-serializer-24.4.0.tgz#f70c5918c8ea9235ccb1276d232e459080588db3" - integrity sha512-k//0DtglVstc1fv+GY/VHDIjrtNjdYvYjMlbLUed4kxrE92sIUewOi5Hj3vrpB8CXfkJntRPDRjCrCvUhBdL8Q== - -jest-snapshot@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-24.5.0.tgz#e5d224468a759fd19e36f01217aac912f500f779" - integrity sha512-eBEeJb5ROk0NcpodmSKnCVgMOo+Qsu5z9EDl3tGffwPzK1yV37mjGWF2YeIz1NkntgTzP+fUL4s09a0+0dpVWA== - dependencies: - "@babel/types" "^7.0.0" - "@jest/types" "^24.5.0" - chalk "^2.0.1" - expect "^24.5.0" - jest-diff "^24.5.0" - jest-matcher-utils "^24.5.0" - jest-message-util "^24.5.0" - jest-resolve "^24.5.0" - mkdirp "^0.5.1" - natural-compare "^1.4.0" - pretty-format "^24.5.0" - semver "^5.5.0" - -jest-util@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-24.5.0.tgz#9d9cb06d9dcccc8e7cc76df91b1635025d7baa84" - integrity sha512-Xy8JsD0jvBz85K7VsTIQDuY44s+hYJyppAhcsHsOsGisVtdhar6fajf2UOf2mEVEgh15ZSdA0zkCuheN8cbr1Q== - dependencies: - "@jest/console" "^24.3.0" - "@jest/fake-timers" "^24.5.0" - "@jest/source-map" "^24.3.0" - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" + graceful-fs "^4.2.9" + jest-circus "^29.7.0" + jest-environment-node "^29.7.0" + jest-get-type "^29.6.3" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-runner "^29.7.0" + jest-util "^29.7.0" + jest-validate "^29.7.0" + micromatch "^4.0.4" + parse-json "^5.2.0" + pretty-format "^29.7.0" + slash "^3.0.0" + strip-json-comments "^3.1.1" + +jest-diff@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-29.7.0.tgz#017934a66ebb7ecf6f205e84699be10afd70458a" + integrity sha512-LMIgiIrhigmPrs03JHpxUh2yISK3vLFPkAodPeo0+BuF7wA2FoQbkEg1u8gBYBThncu7e1oEDUfIXVuTqLRUjw== + dependencies: + chalk "^4.0.0" + diff-sequences "^29.6.3" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-docblock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-29.7.0.tgz#8fddb6adc3cdc955c93e2a87f61cfd350d5d119a" + integrity sha512-q617Auw3A612guyaFgsbFeYpNP5t2aoUNLwBUbc/0kD1R4t9ixDbyFTHd1nok4epoVFpr7PmeWHrhvuV3XaJ4g== + dependencies: + detect-newline "^3.0.0" + +jest-each@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-each/-/jest-each-29.7.0.tgz#162a9b3f2328bdd991beaabffbb74745e56577d1" + integrity sha512-gns+Er14+ZrEoC5fhOfYCY1LOHHr0TI+rQUHZS8Ttw2l7gl+80eHc/gFf2Ktkw0+SIACDTeWvpFcv3B04VembQ== + dependencies: + "@jest/types" "^29.6.3" + chalk "^4.0.0" + jest-get-type "^29.6.3" + jest-util "^29.7.0" + pretty-format "^29.7.0" + +jest-environment-node@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-29.7.0.tgz#0b93e111dda8ec120bc8300e6d1fb9576e164376" + integrity sha512-DOSwCRqXirTOyheM+4d5YZOrWcdu0LNZ87ewUoywbcb2XR4wKgqiG8vNeYwhjFMbEkfju7wx2GYH0P2gevGvFw== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/types" "^29.6.3" "@types/node" "*" - callsites "^3.0.0" - chalk "^2.0.1" - graceful-fs "^4.1.15" - is-ci "^2.0.0" - mkdirp "^0.5.1" - slash "^2.0.0" - source-map "^0.6.0" + jest-mock "^29.7.0" + jest-util "^29.7.0" -jest-validate@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-24.5.0.tgz#62fd93d81214c070bb2d7a55f329a79d8057c7de" - integrity sha512-gg0dYszxjgK2o11unSIJhkOFZqNRQbWOAB2/LOUdsd2LfD9oXiMeuee8XsT0iRy5EvSccBgB4h/9HRbIo3MHgQ== - dependencies: - "@jest/types" "^24.5.0" - camelcase "^5.0.0" - chalk "^2.0.1" - jest-get-type "^24.3.0" - leven "^2.1.0" - pretty-format "^24.5.0" - -jest-watcher@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-24.5.0.tgz#da7bd9cb5967e274889b42078c8f501ae1c47761" - integrity sha512-/hCpgR6bg0nKvD3nv4KasdTxuhwfViVMHUATJlnGCD0r1QrmIssimPbmc5KfAQblAVxkD8xrzuij9vfPUk1/rA== - dependencies: - "@jest/test-result" "^24.5.0" - "@jest/types" "^24.5.0" - "@types/node" "*" - "@types/yargs" "^12.0.9" - ansi-escapes "^3.0.0" - chalk "^2.0.1" - jest-util "^24.5.0" - string-length "^2.0.0" +jest-get-type@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-29.6.3.tgz#36f499fdcea197c1045a127319c0481723908fd1" + integrity sha512-zrteXnqYxfQh7l5FHyL38jL39di8H8rHoecLH3JNxH3BwOrBsNeabdap5e0I23lD4HHI8W5VFBZqG4Eaq5LNcw== -jest-worker@^24.4.0: - version "24.4.0" - resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-24.4.0.tgz#fbc452b0120bb5c2a70cdc88fa132b48eeb11dd0" - integrity sha512-BH9X/klG9vxwoO99ZBUbZFfV8qO0XNZ5SIiCyYK2zOuJBl6YJVAeNIQjcoOVNu4HGEHeYEKsUWws8kSlSbZ9YQ== +jest-haste-map@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-29.7.0.tgz#3c2396524482f5a0506376e6c858c3bbcc17b104" + integrity sha512-fP8u2pyfqx0K1rGn1R9pyE0/KTn+G7PxktWidOBTqFPLYX0b9ksaMFkhK5vrS3DVun09pckLdlx90QthlW7AmA== dependencies: + "@jest/types" "^29.6.3" + "@types/graceful-fs" "^4.1.3" "@types/node" "*" - merge-stream "^1.0.1" - supports-color "^6.1.0" - -jest@^24.0.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/jest/-/jest-24.5.0.tgz#38f11ae2c2baa2f86c2bc4d8a91d2b51612cd19a" - integrity sha512-lxL+Fq5/RH7inxxmfS2aZLCf8MsS+YCUBfeiNO6BWz/MmjhDGaIEA/2bzEf9q4Q0X+mtFHiinHFvQ0u+RvW/qQ== - dependencies: - import-local "^2.0.0" - jest-cli "^24.5.0" - -js-tokens@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b" - integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= - -js-tokens@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" - integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== - -js-yaml@^3.12.0: - version "3.12.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.12.1.tgz#295c8632a18a23e054cf5c9d3cecafe678167600" - integrity sha512-um46hB9wNOKlwkHgiuyEVAybXBjwFUV0Z/RaHJblRd9DXltue9FTYvzCr9ErQrK9Adz5MU4gHWVaNUfdmrC8qA== - dependencies: - argparse "^1.0.7" - esprima "^4.0.0" - -jsbn@~0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" - integrity sha1-peZUwuWi3rXyAdls77yoDA7y9RM= - -jsdom@^11.5.1: - version "11.11.0" - resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.11.0.tgz#df486efad41aee96c59ad7a190e2449c7eb1110e" - integrity sha512-ou1VyfjwsSuWkudGxb03FotDajxAto6USAlmMZjE2lc0jCznt7sBWkhfRBRaWwbnmDqdMSTKTLT5d9sBFkkM7A== - dependencies: - abab "^1.0.4" - acorn "^5.3.0" - acorn-globals "^4.1.0" - array-equal "^1.0.0" - cssom ">= 0.3.2 < 0.4.0" - cssstyle ">= 0.3.1 < 0.4.0" - data-urls "^1.0.0" - domexception "^1.0.0" - escodegen "^1.9.0" - html-encoding-sniffer "^1.0.2" - left-pad "^1.2.0" - nwsapi "^2.0.0" - parse5 "4.0.0" - pn "^1.1.0" - request "^2.83.0" - request-promise-native "^1.0.5" - sax "^1.2.4" - symbol-tree "^3.2.2" - tough-cookie "^2.3.3" - w3c-hr-time "^1.0.1" - webidl-conversions "^4.0.2" - whatwg-encoding "^1.0.3" - whatwg-mimetype "^2.1.0" - whatwg-url "^6.4.1" - ws "^4.0.0" - xml-name-validator "^3.0.0" - -jsesc@^2.5.1: - version "2.5.2" - resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" - integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== - -json-parse-better-errors@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/json-parse-better-errors/-/json-parse-better-errors-1.0.2.tgz#bb867cfb3450e69107c131d1c514bab3dc8bcaa9" - integrity sha512-mrqyZKfX5EhL7hvqcV6WG1yYjnjeuYDzDhhcAAUrq8Po85NBQBJP+ZDUT75qZQ98IkUoBqdkExkukOU7Ts2wrw== - -json-schema-traverse@^0.4.1: - version "0.4.1" - resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" - integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== - -json-schema@0.2.3: - version "0.2.3" - resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13" - integrity sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM= - -json-stable-stringify-without-jsonify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" - integrity sha1-nbe1lJatPzz+8wp1FC0tkwrXJlE= - -json-stringify-safe@~5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" - integrity sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus= - -json5@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.0.tgz#e7a0c62c48285c628d20a10b85c89bb807c32850" - integrity sha512-8Mh9h6xViijj36g7Dxi+Y4S6hNGV96vcJZr/SrlHh1LR/pEn/8j/+qIBbs44YKl69Lrfctp4QD+AdWLTMqEZAQ== - dependencies: - minimist "^1.2.0" - -jsonfile@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" - integrity sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss= + anymatch "^3.0.3" + fb-watchman "^2.0.0" + graceful-fs "^4.2.9" + jest-regex-util "^29.6.3" + jest-util "^29.7.0" + jest-worker "^29.7.0" + micromatch "^4.0.4" + walker "^1.0.8" optionalDependencies: - graceful-fs "^4.1.6" - -jsprim@^1.2.2: - version "1.4.1" - resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" - integrity sha1-MT5mvB5cwG5Di8G3SZwuXFastqI= - dependencies: - assert-plus "1.0.0" - extsprintf "1.3.0" - json-schema "0.2.3" - verror "1.10.0" - -kind-of@^3.0.2, kind-of@^3.0.3, kind-of@^3.2.0: - version "3.2.2" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64" - integrity sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ= - dependencies: - is-buffer "^1.1.5" - -kind-of@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57" - integrity sha1-IIE989cSkosgc3hpGkUGb65y3Vc= - dependencies: - is-buffer "^1.1.5" - -kind-of@^5.0.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-5.1.0.tgz#729c91e2d857b7a419a1f9aa65685c4c33f5845d" - integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== - -kind-of@^6.0.0, kind-of@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" - integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== - -kleur@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.1.tgz#4f5b313f5fa315432a400f19a24db78d451ede62" - integrity sha512-P3kRv+B+Ra070ng2VKQqW4qW7gd/v3iD8sy/zOdcYRsfiD+QBokQNOps/AfP6Hr48cBhIIBFWckB9aO+IZhrWg== - -lcid@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz#6ef5d2df60e52f82eb228a4c373e8d1f397253cf" - integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== - dependencies: - invert-kv "^2.0.0" - -left-pad@^1.2.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/left-pad/-/left-pad-1.3.0.tgz#5b8a3a7765dfe001261dde915589e782f8c94d1e" - integrity sha512-XI5MPzVNApjAyhQzphX8BkmKsKUxD4LdyK24iZeQGinBN9yTQT3bFlCBy/aVx2HrNcqQGsdot8ghrjyrvMCoEA== - -leven@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/leven/-/leven-2.1.0.tgz#c2e7a9f772094dee9d34202ae8acce4687875580" - integrity sha1-wuep93IJTe6dNCAq6KzORoeHVYA= - -levn@^0.3.0, levn@~0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" - integrity sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4= - dependencies: - prelude-ls "~1.1.2" - type-check "~0.3.2" - -load-json-file@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-2.0.0.tgz#7947e42149af80d696cbf797bcaabcfe1fe29ca8" - integrity sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg= - dependencies: - graceful-fs "^4.1.2" - parse-json "^2.2.0" - pify "^2.0.0" - strip-bom "^3.0.0" - -load-json-file@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-4.0.0.tgz#2f5f45ab91e33216234fd53adab668eb4ec0993b" - integrity sha1-L19Fq5HjMhYjT9U62rZo607AmTs= - dependencies: - graceful-fs "^4.1.2" - parse-json "^4.0.0" - pify "^3.0.0" - strip-bom "^3.0.0" - -locate-path@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" - integrity sha1-K1aLJl7slExtnA3pw9u7ygNUzY4= - dependencies: - p-locate "^2.0.0" - path-exists "^3.0.0" - -locate-path@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" - integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== - dependencies: - p-locate "^3.0.0" - path-exists "^3.0.0" - -lodash.sortby@^4.7.0: - version "4.7.0" - resolved "https://registry.yarnpkg.com/lodash.sortby/-/lodash.sortby-4.7.0.tgz#edd14c824e2cc9c1e0b0a1b42bb5210516a42438" - integrity sha1-7dFMgk4sycHgsKG0K7UhBRakJDg= - -lodash@^4.11.2, lodash@^4.13.1, lodash@^4.17.10, lodash@^4.17.11: - version "4.17.11" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.11.tgz#b39ea6229ef607ecd89e2c8df12536891cac9b8d" - integrity sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg== - -loose-envify@^1.0.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.3.1.tgz#d1a8ad33fa9ce0e713d65fdd0ac8b748d478c848" - integrity sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg= - dependencies: - js-tokens "^3.0.0" - -make-dir@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-1.3.0.tgz#79c1033b80515bd6d24ec9933e860ca75ee27f0c" - integrity sha512-2w31R7SJtieJJnQtGc7RVL2StM2vGYVfqUOvUDxH6bC6aJTxPxTF0GnIgCyu7tjockiUWAYQRbxa7vKn34s5sQ== - dependencies: - pify "^3.0.0" - -makeerror@1.0.x: - version "1.0.11" - resolved "https://registry.yarnpkg.com/makeerror/-/makeerror-1.0.11.tgz#e01a5c9109f2af79660e4e8b9587790184f5a96c" - integrity sha1-4BpckQnyr3lmDk6LlYd5AYT1qWw= - dependencies: - tmpl "1.0.x" - -map-age-cleaner@^0.1.1: - version "0.1.3" - resolved "https://registry.yarnpkg.com/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz#7d583a7306434c055fe474b0f45078e6e1b4b92a" - integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== - dependencies: - p-defer "^1.0.0" - -map-cache@^0.2.2: - version "0.2.2" - resolved "https://registry.yarnpkg.com/map-cache/-/map-cache-0.2.2.tgz#c32abd0bd6525d9b051645bb4f26ac5dc98a0dbf" - integrity sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8= - -map-visit@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/map-visit/-/map-visit-1.0.0.tgz#ecdca8f13144e660f1b5bd41f12f3479d98dfb8f" - integrity sha1-7Nyo8TFE5mDxtb1B8S80edmN+48= - dependencies: - object-visit "^1.0.0" - -mem@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/mem/-/mem-4.1.0.tgz#aeb9be2d21f47e78af29e4ac5978e8afa2ca5b8a" - integrity sha512-I5u6Q1x7wxO0kdOpYBB28xueHADYps5uty/zg936CiG8NTe5sJL8EjrCuLneuDW3PlMdZBGDIn8BirEVdovZvg== - dependencies: - map-age-cleaner "^0.1.1" - mimic-fn "^1.0.0" - p-is-promise "^2.0.0" - -merge-stream@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-1.0.1.tgz#4041202d508a342ba00174008df0c251b8c135e1" - integrity sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE= - dependencies: - readable-stream "^2.0.1" + fsevents "^2.3.2" + +jest-leak-detector@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-leak-detector/-/jest-leak-detector-29.7.0.tgz#5b7ec0dadfdfec0ca383dc9aa016d36b5ea4c728" + integrity sha512-kYA8IJcSYtST2BY9I+SMC32nDpBT3J2NvWJx8+JCuCdl/CR1I4EKUJROiP8XtCcxqgTTBGJNdbB1A8XRKbTetw== + dependencies: + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-matcher-utils@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-29.7.0.tgz#ae8fec79ff249fd592ce80e3ee474e83a6c44f12" + integrity sha512-sBkD+Xi9DtcChsI3L3u0+N0opgPYnCRPtGcQYrgXmR+hmt/fYfWAL0xRXYU8eWOdfuLgBe0YCW3AFtnRLagq/g== + dependencies: + chalk "^4.0.0" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + pretty-format "^29.7.0" + +jest-message-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-29.7.0.tgz#8bc392e204e95dfe7564abbe72a404e28e51f7f3" + integrity sha512-GBEV4GRADeP+qtB2+6u61stea8mGcOT4mCtrYISZwfu9/ISHFJ/5zOMXYbpBE9RsS5+Gb63DW4FgmnKJ79Kf6w== + dependencies: + "@babel/code-frame" "^7.12.13" + "@jest/types" "^29.6.3" + "@types/stack-utils" "^2.0.0" + chalk "^4.0.0" + graceful-fs "^4.2.9" + micromatch "^4.0.4" + pretty-format "^29.7.0" + slash "^3.0.0" + stack-utils "^2.0.3" + +jest-mock@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-29.7.0.tgz#4e836cf60e99c6fcfabe9f99d017f3fdd50a6347" + integrity sha512-ITOMZn+UkYS4ZFh83xYAOzWStloNzJFO2s8DWrE4lhtGD+AorgnbkiKERe4wQVBydIGPx059g6riW5Btp6Llnw== + dependencies: + "@jest/types" "^29.6.3" + "@types/node" "*" + jest-util "^29.7.0" -merge2@^1.2.3: +jest-pnp-resolver@^1.2.2: version "1.2.3" - resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.2.3.tgz#7ee99dbd69bb6481689253f018488a1b902b0ed5" - integrity sha512-gdUU1Fwj5ep4kplwcmftruWofEFt6lfpkkr3h860CXbAB9c3hGb55EOL2ali0Td5oebvW0E1+3Sr+Ur7XfKpRA== - -micromatch@^3.1.10, micromatch@^3.1.4: - version "3.1.10" - resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" - integrity sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg== - dependencies: - arr-diff "^4.0.0" - array-unique "^0.3.2" - braces "^2.3.1" - define-property "^2.0.2" - extend-shallow "^3.0.2" - extglob "^2.0.4" - fragment-cache "^0.2.1" - kind-of "^6.0.2" - nanomatch "^1.2.9" - object.pick "^1.3.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.2" - -mime-db@~1.33.0: - version "1.33.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db" - integrity sha512-BHJ/EKruNIqJf/QahvxwQZXKygOQ256myeN/Ew+THcAa5q+PjyTTMMeNQC4DZw5AwfvelsUrA6B67NKMqXDbzQ== - -mime-db@~1.38.0: - version "1.38.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.38.0.tgz#1a2aab16da9eb167b49c6e4df2d9c68d63d8e2ad" - integrity sha512-bqVioMFFzc2awcdJZIzR3HjZFX20QhilVS7hytkKrv7xFAn8bM1gzc/FOX2awLISvWe0PV8ptFKcon+wZ5qYkg== - -mime-types@^2.1.12: - version "2.1.18" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.18.tgz#6f323f60a83d11146f831ff11fd66e2fe5503bb8" - integrity sha512-lc/aahn+t4/SWV/qcmumYjymLsWfN3ELhpmVuUFjgsORruuZPVSwAQryq+HHGvO/SI2KVX26bx+En+zhM8g8hQ== - dependencies: - mime-db "~1.33.0" - -mime-types@~2.1.19: - version "2.1.22" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.22.tgz#fe6b355a190926ab7698c9a0556a11199b2199bd" - integrity sha512-aGl6TZGnhm/li6F7yx82bJiBZwgiEa4Hf6CNr8YO+r5UHr53tSTYZb102zyU50DOWWKeOv0uQLRL0/9EiKWCog== - dependencies: - mime-db "~1.38.0" - -mimic-fn@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022" - integrity sha512-jf84uxzwiuiIVKiOLpfYk7N46TSy8ubTonmneY9vrpHNAnp0QBt2BxWV9dO3/j+BoVAb+a5G6YDPW3M5HOdMWQ== - -minimatch@^3.0.3, minimatch@^3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" - integrity sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA== - dependencies: - brace-expansion "^1.1.7" - -minimist@0.0.8: - version "0.0.8" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" - integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= - -minimist@1.2.0, minimist@^1.1.1, minimist@^1.2.0, minimist@~1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" - integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= - -minimist@~0.0.1: - version "0.0.10" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" - integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= - -mixin-deep@^1.2.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe" - integrity sha512-8ZItLHeEgaqEvd5lYBXfm4EZSFCX29Jb9K+lAHhDKzReKBQKj3R+7NOF6tjqYi9t4oI8VUfaWITJQm86wnXGNQ== - dependencies: - for-in "^1.0.2" - is-extendable "^1.0.1" - -mkdirp@^0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" - integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= - dependencies: - minimist "0.0.8" - -ms@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g= - -ms@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.1.tgz#30a5864eb3ebb0a66f2ebe6d727af06a09d86e0a" - integrity sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg== - -multistream@2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/multistream/-/multistream-2.1.1.tgz#629d3a29bd76623489980d04519a2c365948148c" - integrity sha512-xasv76hl6nr1dEy3lPvy7Ej7K/Lx3O/FCvwge8PeVJpciPPoNCbaANcNiBug3IpdvTveZUcAV0DJzdnUDMesNQ== - dependencies: - inherits "^2.0.1" - readable-stream "^2.0.5" - -mute-stream@0.0.7: - version "0.0.7" - resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" - integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= - -nanomatch@^1.2.9: - version "1.2.9" - resolved "https://registry.yarnpkg.com/nanomatch/-/nanomatch-1.2.9.tgz#879f7150cb2dab7a471259066c104eee6e0fa7c2" - integrity sha512-n8R9bS8yQ6eSXaV6jHUpKzD8gLsin02w1HSFiegwrs9E098Ylhw5jdyKPaYqvHknHaSCKTPp7C8dGCQ0q9koXA== - dependencies: - arr-diff "^4.0.0" - array-unique "^0.3.2" - define-property "^2.0.2" - extend-shallow "^3.0.2" - fragment-cache "^0.2.1" - is-odd "^2.0.0" - is-windows "^1.0.2" - kind-of "^6.0.2" - object.pick "^1.3.0" - regex-not "^1.0.0" - snapdragon "^0.8.1" - to-regex "^3.0.1" - -natural-compare@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" - integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= - -nice-try@^1.0.4: - version "1.0.5" - resolved "https://registry.yarnpkg.com/nice-try/-/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" - integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== - -node-int64@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" - integrity sha1-h6kGXNs1XTGC2PlM4RGIuCXGijs= - -node-modules-regexp@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/node-modules-regexp/-/node-modules-regexp-1.0.0.tgz#8d9dbe28964a4ac5712e9131642107c71e90ec40" - integrity sha1-jZ2+KJZKSsVxLpExZCEHxx6Q7EA= - -node-notifier@^5.2.1: - version "5.2.1" - resolved "https://registry.yarnpkg.com/node-notifier/-/node-notifier-5.2.1.tgz#fa313dd08f5517db0e2502e5758d664ac69f9dea" - integrity sha512-MIBs+AAd6dJ2SklbbE8RUDRlIVhU8MaNLh1A9SUZDUHPiZkWLFde6UNwG41yQHZEToHgJMXqyVZ9UcS/ReOVTg== - dependencies: - growly "^1.3.0" - semver "^5.4.1" - shellwords "^0.1.1" - which "^1.3.0" - -normalize-package-data@^2.3.2: - version "2.4.0" - resolved "https://registry.yarnpkg.com/normalize-package-data/-/normalize-package-data-2.4.0.tgz#12f95a307d58352075a04907b84ac8be98ac012f" - integrity sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw== - dependencies: - hosted-git-info "^2.1.4" - is-builtin-module "^1.0.0" - semver "2 || 3 || 4 || 5" - validate-npm-package-license "^3.0.1" - -normalize-path@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-2.1.1.tgz#1ab28b556e198363a8c1a6f7e6fa20137fe6aed9" - integrity sha1-GrKLVW4Zg2Oowab35vogE3/mrtk= - dependencies: - remove-trailing-separator "^1.0.1" - -npm-run-path@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" - integrity sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8= - dependencies: - path-key "^2.0.0" - -number-is-nan@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" - integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= - -nwsapi@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.0.0.tgz#7c8faf4ad501e1d17a651ebc5547f966b547c5c7" - integrity sha512-9kj1oCEDNq+LHDAVPGDPg9+qRcBcpXb1IYC8q89jR8xJvOC2byQwEVsM3W1qQcSPVyzGGaXN7wZHnXORCiZl4w== - -oauth-sign@~0.9.0: - version "0.9.0" - resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" - integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== - -object-copy@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/object-copy/-/object-copy-0.1.0.tgz#7e7d858b781bd7c991a41ba975ed3812754e998c" - integrity sha1-fn2Fi3gb18mRpBupde04EnVOmYw= - dependencies: - copy-descriptor "^0.1.0" - define-property "^0.2.5" - kind-of "^3.0.3" - -object-keys@^1.0.11, object-keys@^1.0.12: - version "1.1.0" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.0.tgz#11bd22348dd2e096a045ab06f6c85bcc340fa032" - integrity sha512-6OO5X1+2tYkNyNEx6TsCxEqFfRWaqx6EtMiSbGrw8Ob8v9Ne+Hl8rBAgLBZn5wjEz3s/s6U1WXFUFOcxxAwUpg== - -object-keys@^1.0.8: - version "1.0.11" - resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d" - integrity sha1-xUYBd4rVYPEULODgG8yotW0TQm0= - -object-visit@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/object-visit/-/object-visit-1.0.1.tgz#f79c4493af0c5377b59fe39d395e41042dd045bb" - integrity sha1-95xEk68MU3e1n+OdOV5BBC3QRbs= - dependencies: - isobject "^3.0.0" - -object.assign@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.0.tgz#968bf1100d7956bb3ca086f006f846b3bc4008da" - integrity sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w== - dependencies: - define-properties "^1.1.2" - function-bind "^1.1.1" - has-symbols "^1.0.0" - object-keys "^1.0.11" - -object.entries@^1.0.4: - version "1.1.0" - resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.0.tgz#2024fc6d6ba246aee38bdb0ffd5cfbcf371b7519" - integrity sha512-l+H6EQ8qzGRxbkHOd5I/aHRhHDKoQXQ8g0BYt4uSweQU1/J6dZUOyWh9a2Vky35YCKjzmgxOzta2hH6kf9HuXA== - dependencies: - define-properties "^1.1.3" - es-abstract "^1.12.0" - function-bind "^1.1.1" - has "^1.0.3" - -object.getownpropertydescriptors@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz#8758c846f5b407adab0f236e0986f14b051caa16" - integrity sha1-h1jIRvW0B62rDyNuCYbxSwUcqhY= - dependencies: - define-properties "^1.1.2" - es-abstract "^1.5.1" - -object.pick@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.3.0.tgz#87a10ac4c1694bd2e1cbf53591a66141fb5dd747" - integrity sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c= - dependencies: - isobject "^3.0.1" - -once@^1.3.0, once@^1.3.1, once@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" - integrity sha1-WDsap3WWHUsROsF9nFC6753Xa9E= - dependencies: - wrappy "1" - -onetime@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/onetime/-/onetime-2.0.1.tgz#067428230fd67443b2794b22bba528b6867962d4" - integrity sha1-BnQoIw/WdEOyeUsiu6UotoZ5YtQ= - dependencies: - mimic-fn "^1.0.0" - -optimist@^0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686" - integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY= - dependencies: - minimist "~0.0.1" - wordwrap "~0.0.2" - -optionator@^0.8.1, optionator@^0.8.2: - version "0.8.2" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" - integrity sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q= - dependencies: - deep-is "~0.1.3" - fast-levenshtein "~2.0.4" - levn "~0.3.0" - prelude-ls "~1.1.2" - type-check "~0.3.2" - wordwrap "~1.0.0" - -os-locale@^3.0.0, os-locale@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-3.1.0.tgz#a802a6ee17f24c10483ab9935719cef4ed16bf1a" - integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== - dependencies: - execa "^1.0.0" - lcid "^2.0.0" - mem "^4.0.0" - -os-tmpdir@^1.0.1, os-tmpdir@~1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" - integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= - -p-defer@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-defer/-/p-defer-1.0.0.tgz#9f6eb182f6c9aa8cd743004a7d4f96b196b0fb0c" - integrity sha1-n26xgvbJqozXQwBKfU+WsZaw+ww= - -p-each-series@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-each-series/-/p-each-series-1.0.0.tgz#930f3d12dd1f50e7434457a22cd6f04ac6ad7f71" - integrity sha1-kw89Et0fUOdDRFeiLNbwSsatf3E= - dependencies: - p-reduce "^1.0.0" - -p-finally@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-finally/-/p-finally-1.0.0.tgz#3fbcfb15b899a44123b34b6dcc18b724336a2cae" - integrity sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4= - -p-is-promise@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/p-is-promise/-/p-is-promise-2.0.0.tgz#7554e3d572109a87e1f3f53f6a7d85d1b194f4c5" - integrity sha512-pzQPhYMCAgLAKPWD2jC3Se9fEfrD9npNos0y150EeqZll7akhEgGhTW/slB6lHku8AvYGiJ+YJ5hfHKePPgFWg== - -p-limit@^1.1.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" - integrity sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q== - dependencies: - p-try "^1.0.0" - -p-limit@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.1.0.tgz#1d5a0d20fb12707c758a655f6bbc4386b5930d68" - integrity sha512-NhURkNcrVB+8hNfLuysU8enY5xn2KXphsHBaC2YmRNTZRc7RWusw6apSpdEj3jo4CMb6W9nrF6tTnsJsJeyu6g== - dependencies: - p-try "^2.0.0" - -p-locate@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-2.0.0.tgz#20a0103b222a70c8fd39cc2e580680f3dde5ec43" - integrity sha1-IKAQOyIqcMj9OcwuWAaA893l7EM= - dependencies: - p-limit "^1.1.0" - -p-locate@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" - integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== - dependencies: - p-limit "^2.0.0" - -p-reduce@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-reduce/-/p-reduce-1.0.0.tgz#18c2b0dd936a4690a529f8231f58a0fdb6a47dfa" - integrity sha1-GMKw3ZNqRpClKfgjH1ig/bakffo= - -p-try@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" - integrity sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M= - -p-try@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.0.0.tgz#85080bb87c64688fa47996fe8f7dfbe8211760b1" - integrity sha512-hMp0onDKIajHfIkdRk3P4CdCmErkYAxxDtP3Wx/4nZ3aGlau2VKh3mZpcuFkH27WQkL/3WBCPOktzA9ZOAnMQQ== - -parent-module@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.0.tgz#df250bdc5391f4a085fb589dad761f5ad6b865b5" - integrity sha512-8Mf5juOMmiE4FcmzYc4IaiS9L3+9paz2KOiXzkRviCP6aDmN49Hz6EMWz0lGNp9pX80GvvAuLADtyGfW/Em3TA== - dependencies: - callsites "^3.0.0" - -parse-json@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-2.2.0.tgz#f480f40434ef80741f8469099f8dea18f55a4dc9" - integrity sha1-9ID0BDTvgHQfhGkJn43qGPVaTck= - dependencies: - error-ex "^1.2.0" - -parse-json@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0" - integrity sha1-vjX1Qlvh9/bHRxhPmKeIy5lHfuA= - dependencies: - error-ex "^1.3.1" - json-parse-better-errors "^1.0.1" - -parse5@4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/parse5/-/parse5-4.0.0.tgz#6d78656e3da8d78b4ec0b906f7c08ef1dfe3f608" - integrity sha512-VrZ7eOd3T1Fk4XWNXMgiGBK/z0MG48BWG2uQNU4I72fkQuKUTZpl+u9k+CxEG0twMVzSmXEEz12z5Fnw1jIQFA== - -pascalcase@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/pascalcase/-/pascalcase-0.1.1.tgz#b363e55e8006ca6fe21784d2db22bd15d7917f14" - integrity sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ= - -path-dirname@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/path-dirname/-/path-dirname-1.0.2.tgz#cc33d24d525e099a5388c0336c6e32b9160609e0" - integrity sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA= - -path-exists@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" - integrity sha1-zg6+ql94yxiSXqfYENe1mwEP1RU= - -path-is-absolute@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" - integrity sha1-F0uSaHNVNP+8es5r9TpanhtcX18= - -path-is-inside@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/path-is-inside/-/path-is-inside-1.0.2.tgz#365417dede44430d1c11af61027facf074bdfc53" - integrity sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM= - -path-key@^2.0.0, path-key@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40" - integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A= - -path-parse@^1.0.5, path-parse@^1.0.6: - version "1.0.6" - resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.6.tgz#d62dbb5679405d72c4737ec58600e9ddcf06d24c" - integrity sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw== - -path-type@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/path-type/-/path-type-2.0.0.tgz#f012ccb8415b7096fc2daa1054c3d72389594c73" - integrity sha1-8BLMuEFbcJb8LaoQVMPXI4lZTHM= - dependencies: - pify "^2.0.0" - -path-type@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/path-type/-/path-type-3.0.0.tgz#cef31dc8e0a1a3bb0d105c0cd97cf3bf47f4e36f" - integrity sha512-T2ZUsdZFHgA3u4e5PfPbjd7HDDpxPnQb5jN0SrDsjNSuVXHJqtwTnWqG0B1jZrgmJ/7lj1EmVIByWt1gxGkWvg== - dependencies: - pify "^3.0.0" - -performance-now@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" - integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= - -pify@^2.0.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c" - integrity sha1-7RQaasBDqEnqWISY59yosVMw6Qw= - -pify@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" - integrity sha1-5aSs0sEB/fPZpNB/DbxNtJ3SgXY= - -pify@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/pify/-/pify-4.0.1.tgz#4b2cd25c50d598735c50292224fd8c6df41e3231" - integrity sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g== - -pirates@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.1.tgz#643a92caf894566f91b2b986d2c66950a8e2fb87" - integrity sha512-WuNqLTbMI3tmfef2TKxlQmAiLHKtFhlsCZnPIpuv2Ow0RDVO8lfy1Opf4NUzlMXLjPl+Men7AuVdX6TA+s+uGA== - dependencies: - node-modules-regexp "^1.0.0" - -pkg-dir@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-2.0.0.tgz#f6d5d1109e19d63edf428e0bd57e12777615334b" - integrity sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s= - dependencies: - find-up "^2.1.0" - -pkg-dir@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-3.0.0.tgz#2749020f239ed990881b1f71210d51eb6523bea3" - integrity sha512-/E57AYkoeQ25qkxMj5PBOVgF8Kiu/h7cYS30Z5+R7WaiCCBfLq58ZI/dSeaEKb9WVJV5n/03QwrN3IeWIFllvw== - dependencies: - find-up "^3.0.0" - -pkg-fetch@2.5.7: - version "2.5.7" - resolved "https://registry.yarnpkg.com/pkg-fetch/-/pkg-fetch-2.5.7.tgz#f253fce31eb62d40547af0761cf824e0751bff09" - integrity sha512-fm9aVV3ZRdFYTyFYcSHuKMuxPCVQ0MD9tbVxbvQzFTg1gwvV0KqWrFoj5enVVha94yP83I50XEBa90X8L9fE8w== - dependencies: - babel-runtime "~6.26.0" - byline "~5.0.0" - chalk "~2.4.1" - expand-template "~1.1.1" - fs-extra "~6.0.1" - in-publish "~2.0.0" - minimist "~1.2.0" - progress "~2.0.0" - request "~2.88.0" - request-progress "~3.0.0" - semver "~5.6.0" - unique-temp-dir "~1.0.0" - -pkg@^4.3.7: - version "4.3.7" - resolved "https://registry.yarnpkg.com/pkg/-/pkg-4.3.7.tgz#a80767283d728adbcdf668ad99250af440efd8e3" - integrity sha512-/BvtFft1nKKtnTuOm/0es0sk1cOs7ZtWgJpqdtszJ4348jYJ8owVyCB/iuGhI3YJFX/ZFIv4Rmra9ETUgpnnfA== - dependencies: - "@babel/parser" "7.2.3" - babel-runtime "6.26.0" - chalk "2.4.2" - escodegen "1.11.0" - fs-extra "7.0.1" - globby "8.0.2" - into-stream "4.0.0" - minimist "1.2.0" - multistream "2.1.1" - pkg-fetch "2.5.7" - progress "2.0.3" - resolve "1.6.0" - stream-meter "1.0.4" - -pn@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/pn/-/pn-1.1.0.tgz#e2f4cef0e219f463c179ab37463e4e1ecdccbafb" - integrity sha512-2qHaIQr2VLRFoxe2nASzsV6ef4yOOH+Fi9FBOVH6cqeSgUnoyySPZkxzLuzd+RYOQTRpROA0ztTMqxROKSb/nA== - -posix-character-classes@^0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/posix-character-classes/-/posix-character-classes-0.1.1.tgz#01eac0fe3b5af71a2a6c02feabb8c1fef7e00eab" - integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= - -prelude-ls@~1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54" - integrity sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ= - -prettier@^1.16.4: - version "1.16.4" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.16.4.tgz#73e37e73e018ad2db9c76742e2647e21790c9717" - integrity sha512-ZzWuos7TI5CKUeQAtFd6Zhm2s6EpAD/ZLApIhsF9pRvRtM1RFo61dM/4MSRUA0SuLugA/zgrZD8m0BaY46Og7g== - -pretty-format@^24.5.0: - version "24.5.0" - resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-24.5.0.tgz#cc69a0281a62cd7242633fc135d6930cd889822d" - integrity sha512-/3RuSghukCf8Riu5Ncve0iI+BzVkbRU5EeUoArKARZobREycuH5O4waxvaNIloEXdb0qwgmEAed5vTpX1HNROQ== - dependencies: - "@jest/types" "^24.5.0" - ansi-regex "^4.0.0" - ansi-styles "^3.2.0" - react-is "^16.8.4" - -process-nextick-args@~2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.0.tgz#a37d732f4271b4ab1ad070d35508e8290788ffaa" - integrity sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw== - -progress@2.0.3, progress@^2.0.0, progress@~2.0.0: - version "2.0.3" - resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" - integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== + resolved "https://registry.yarnpkg.com/jest-pnp-resolver/-/jest-pnp-resolver-1.2.3.tgz#930b1546164d4ad5937d5540e711d4d38d4cad2e" + integrity sha512-+3NpwQEnRoIBtx4fyhblQDPgJI0H1IEIkX7ShLUjPGA7TtUTvI1oiKi3SR4oBR0hQhQR80l4WAe5RrXBwWMA8w== + +jest-regex-util@^29.6.3: + version "29.6.3" + resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-29.6.3.tgz#4a556d9c776af68e1c5f48194f4d0327d24e8a52" + integrity sha512-KJJBsRCyyLNWCNBOvZyRDnAIfUiRJ8v+hOBQYGn8gDyF3UegwiP4gwRR3/SDa42g1YbVycTidUF3rKjyLFDWbg== + +jest-resolve-dependencies@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-29.7.0.tgz#1b04f2c095f37fc776ff40803dc92921b1e88428" + integrity sha512-un0zD/6qxJ+S0et7WxeI3H5XSe9lTBBR7bOHCHXkKR6luG5mwDDlIzVQ0V5cZCuoTgEdcdwzTghYkTWfubi+nA== + dependencies: + jest-regex-util "^29.6.3" + jest-snapshot "^29.7.0" + +jest-resolve@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-29.7.0.tgz#64d6a8992dd26f635ab0c01e5eef4399c6bcbc30" + integrity sha512-IOVhZSrg+UvVAshDSDtHyFCCBUl/Q3AAJv8iZ6ZjnZ74xzvwuzLXid9IIIPgTnY62SJjfuupMKZsZQRsCvxEgA== + dependencies: + chalk "^4.0.0" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-pnp-resolver "^1.2.2" + jest-util "^29.7.0" + jest-validate "^29.7.0" + resolve "^1.20.0" + resolve.exports "^2.0.0" + slash "^3.0.0" + +jest-runner@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-29.7.0.tgz#809af072d408a53dcfd2e849a4c976d3132f718e" + integrity sha512-fsc4N6cPCAahybGBfTRcq5wFR6fpLznMg47sY5aDpsoejOcVYFb07AHuSnR0liMcPTgBsA3ZJL6kFOjPdoNipQ== + dependencies: + "@jest/console" "^29.7.0" + "@jest/environment" "^29.7.0" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + emittery "^0.13.1" + graceful-fs "^4.2.9" + jest-docblock "^29.7.0" + jest-environment-node "^29.7.0" + jest-haste-map "^29.7.0" + jest-leak-detector "^29.7.0" + jest-message-util "^29.7.0" + jest-resolve "^29.7.0" + jest-runtime "^29.7.0" + jest-util "^29.7.0" + jest-watcher "^29.7.0" + jest-worker "^29.7.0" + p-limit "^3.1.0" + source-map-support "0.5.13" + +jest-runtime@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-29.7.0.tgz#efecb3141cf7d3767a3a0cc8f7c9990587d3d817" + integrity sha512-gUnLjgwdGqW7B4LvOIkbKs9WGbn+QLqRQQ9juC6HndeDiezIwhDP+mhMwHWCEcfQ5RUXa6OPnFF8BJh5xegwwQ== + dependencies: + "@jest/environment" "^29.7.0" + "@jest/fake-timers" "^29.7.0" + "@jest/globals" "^29.7.0" + "@jest/source-map" "^29.6.3" + "@jest/test-result" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + cjs-module-lexer "^1.0.0" + collect-v8-coverage "^1.0.0" + glob "^7.1.3" + graceful-fs "^4.2.9" + jest-haste-map "^29.7.0" + jest-message-util "^29.7.0" + jest-mock "^29.7.0" + jest-regex-util "^29.6.3" + jest-resolve "^29.7.0" + jest-snapshot "^29.7.0" + jest-util "^29.7.0" + slash "^3.0.0" + strip-bom "^4.0.0" + +jest-snapshot@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-29.7.0.tgz#c2c574c3f51865da1bb329036778a69bf88a6be5" + integrity sha512-Rm0BMWtxBcioHr1/OX5YCP8Uov4riHvKPknOGs804Zg9JGZgmIBkbtlxJC/7Z4msKYVbIJtfU+tKb8xlYNfdkw== + dependencies: + "@babel/core" "^7.11.6" + "@babel/generator" "^7.7.2" + "@babel/plugin-syntax-jsx" "^7.7.2" + "@babel/plugin-syntax-typescript" "^7.7.2" + "@babel/types" "^7.3.3" + "@jest/expect-utils" "^29.7.0" + "@jest/transform" "^29.7.0" + "@jest/types" "^29.6.3" + babel-preset-current-node-syntax "^1.0.0" + chalk "^4.0.0" + expect "^29.7.0" + graceful-fs "^4.2.9" + jest-diff "^29.7.0" + jest-get-type "^29.6.3" + jest-matcher-utils "^29.7.0" + jest-message-util "^29.7.0" + jest-util "^29.7.0" + natural-compare "^1.4.0" + pretty-format "^29.7.0" + semver "^7.5.3" -prompts@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.0.1.tgz#201b3718b4276fb407f037db48c0029d6465245c" - integrity sha512-8lnEOSIGQbgbnO47+13S+H204L8ISogGulyi0/NNEFAQ9D1VMNTrJ9SBX2Ra03V4iPn/zt36HQMndRYkaPoWiQ== +jest-util@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-29.7.0.tgz#23c2b62bfb22be82b44de98055802ff3710fc0bc" + integrity sha512-z6EbKajIpqGKU56y5KBUgy1dt1ihhQJgWzUlZHArA/+X2ad7Cb5iF+AK1EWVL/Bo7Rz9uurpqw6SiBCefUbCGA== dependencies: - kleur "^3.0.0" - sisteransi "^1.0.0" - -psl@^1.1.24: - version "1.1.31" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.1.31.tgz#e9aa86d0101b5b105cbe93ac6b784cd547276184" - integrity sha512-/6pt4+C+T+wZUieKR620OpzN/LlnNKuWjy1iFLQ/UG35JqHlR/89MP1d96dUfkf6Dne3TuLQzOYEYshJ+Hx8mw== + "@jest/types" "^29.6.3" + "@types/node" "*" + chalk "^4.0.0" + ci-info "^3.2.0" + graceful-fs "^4.2.9" + picomatch "^2.2.3" + +jest-validate@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-29.7.0.tgz#7bf705511c64da591d46b15fce41400d52147d9c" + integrity sha512-ZB7wHqaRGVw/9hST/OuFUReG7M8vKeq0/J2egIGLdvjHCmYqGARhzXmtgi+gVeZ5uXFF219aOc3Ls2yLg27tkw== + dependencies: + "@jest/types" "^29.6.3" + camelcase "^6.2.0" + chalk "^4.0.0" + jest-get-type "^29.6.3" + leven "^3.1.0" + pretty-format "^29.7.0" + +jest-watcher@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-watcher/-/jest-watcher-29.7.0.tgz#7810d30d619c3a62093223ce6bb359ca1b28a2f2" + integrity sha512-49Fg7WXkU3Vl2h6LbLtMQ/HyB6rXSIX7SqvBLQmssRBGN9I0PNvPmAmCWSOY6SOvrjhI/F7/bGAv9RtnsPA03g== + dependencies: + "@jest/test-result" "^29.7.0" + "@jest/types" "^29.6.3" + "@types/node" "*" + ansi-escapes "^4.2.1" + chalk "^4.0.0" + emittery "^0.13.1" + jest-util "^29.7.0" + string-length "^4.0.1" -pump@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" - integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== +jest-worker@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest-worker/-/jest-worker-29.7.0.tgz#acad073acbbaeb7262bd5389e1bcf43e10058d4a" + integrity sha512-eIz2msL/EzL9UFTFFx7jBTkeZfku0yUAyZZZmJ93H2TYEiroIx2PQjEXcwYtYl8zXCxb+PAmA2hLIt/6ZEkPHw== dependencies: - end-of-stream "^1.1.0" - once "^1.3.1" - -punycode@^1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" - integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= - -punycode@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" - integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== - -qs@~6.5.2: - version "6.5.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" - integrity sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA== - -react-is@^16.8.4: - version "16.8.4" - resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.8.4.tgz#90f336a68c3a29a096a3d648ab80e87ec61482a2" - integrity sha512-PVadd+WaUDOAciICm/J1waJaSvgq+4rHE/K70j0PFqKhkTBsPv/82UGQJNXAngz1fOQLLxI6z1sEDmJDQhCTAA== + "@types/node" "*" + jest-util "^29.7.0" + merge-stream "^2.0.0" + supports-color "^8.0.0" -read-pkg-up@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-2.0.0.tgz#6b72a8048984e0c41e79510fd5e9fa99b3b549be" - integrity sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4= +jest@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/jest/-/jest-29.7.0.tgz#994676fc24177f088f1c5e3737f5697204ff2613" + integrity sha512-NIy3oAFp9shda19hy4HK0HRTWKtPJmGdnvywu01nOqNC2vZg+Z+fvJDxpMQA88eb2I9EcafcdjYgsDthnYTvGw== dependencies: - find-up "^2.0.0" - read-pkg "^2.0.0" + "@jest/core" "^29.7.0" + "@jest/types" "^29.6.3" + import-local "^3.0.2" + jest-cli "^29.7.0" -read-pkg-up@^4.0.0: +js-tokens@^4.0.0: version "4.0.0" - resolved "https://registry.yarnpkg.com/read-pkg-up/-/read-pkg-up-4.0.0.tgz#1b221c6088ba7799601c808f91161c66e58f8978" - integrity sha512-6etQSH7nJGsK0RbG/2TeDzZFa8shjQ1um+SwQQ5cwKy0dhSXdOncEhb1CPpvQG4h7FyOV6EB6YlV0yJvZQNAkA== - dependencies: - find-up "^3.0.0" - read-pkg "^3.0.0" - -read-pkg@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-2.0.0.tgz#8ef1c0623c6a6db0dc6713c4bfac46332b2368f8" - integrity sha1-jvHAYjxqbbDcZxPEv6xGMysjaPg= - dependencies: - load-json-file "^2.0.0" - normalize-package-data "^2.3.2" - path-type "^2.0.0" - -read-pkg@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/read-pkg/-/read-pkg-3.0.0.tgz#9cbc686978fee65d16c00e2b19c237fcf6e38389" - integrity sha1-nLxoaXj+5l0WwA4rGcI3/Pbjg4k= - dependencies: - load-json-file "^4.0.0" - normalize-package-data "^2.3.2" - path-type "^3.0.0" - -readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.5, readable-stream@^2.1.4: - version "2.3.6" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" - integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== - dependencies: - core-util-is "~1.0.0" - inherits "~2.0.3" - isarray "~1.0.0" - process-nextick-args "~2.0.0" - safe-buffer "~5.1.1" - string_decoder "~1.1.1" - util-deprecate "~1.0.1" - -realpath-native@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/realpath-native/-/realpath-native-1.1.0.tgz#2003294fea23fb0672f2476ebe22fcf498a2d65c" - integrity sha512-wlgPA6cCIIg9gKz0fgAPjnzh4yR/LnXovwuo9hvyGvx3h8nX4+/iLZplfUWasXpqD8BdnGnP5njOFjkUwPzvjA== - dependencies: - util.promisify "^1.0.0" - -regenerator-runtime@^0.11.0: - version "0.11.1" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9" - integrity sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg== - -regenerator-runtime@^0.12.0: - version "0.12.1" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.12.1.tgz#fa1a71544764c036f8c49b13a08b2594c9f8a0de" - integrity sha512-odxIc1/vDlo4iZcfXqRYFj0vpXFNoGdKMAUieAlFYO6m/nl5e9KR/beGf41z4a1FI+aQgtjhuaSlDxQ0hmkrHg== - -regex-not@^1.0.0, regex-not@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/regex-not/-/regex-not-1.0.2.tgz#1f4ece27e00b0b65e0247a6810e6a85d83a5752c" - integrity sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A== - dependencies: - extend-shallow "^3.0.2" - safe-regex "^1.1.0" - -regexpp@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" - integrity sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw== - -remove-trailing-separator@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz#c24bce2a283adad5bc3f58e0d48249b92379d8ef" - integrity sha1-wkvOKig62tW8P1jg1IJJuSN52O8= - -repeat-element@^1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a" - integrity sha1-7wiaF40Ug7quTZPrmLT55OEdmQo= - -repeat-string@^1.6.1: - version "1.6.1" - resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" - integrity sha1-jcrkcOHIirwtYA//Sndihtp15jc= + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== -request-progress@~3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/request-progress/-/request-progress-3.0.0.tgz#4ca754081c7fec63f505e4faa825aa06cd669dbe" - integrity sha1-TKdUCBx/7GP1BeT6qCWqBs1mnb4= +js-yaml@^3.13.1: + version "3.14.1" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.1.tgz#dae812fdb3825fa306609a8717383c50c36a0537" + integrity sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g== dependencies: - throttleit "^1.0.0" + argparse "^1.0.7" + esprima "^4.0.0" -request-promise-core@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.1.tgz#3eee00b2c5aa83239cfb04c5700da36f81cd08b6" - integrity sha1-Pu4AssWqgyOc+wTFcA2jb4HNCLY= +js-yaml@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602" + integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== dependencies: - lodash "^4.13.1" + argparse "^2.0.1" -request-promise-native@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.5.tgz#5281770f68e0c9719e5163fd3fab482215f4fda5" - integrity sha1-UoF3D2jgyXGeUWP9P6tIIhX0/aU= - dependencies: - request-promise-core "1.1.1" - stealthy-require "^1.1.0" - tough-cookie ">=2.3.3" - -request@^2.72.0, request@^2.83.0, request@~2.88.0: - version "2.88.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" - integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== - dependencies: - aws-sign2 "~0.7.0" - aws4 "^1.8.0" - caseless "~0.12.0" - combined-stream "~1.0.6" - extend "~3.0.2" - forever-agent "~0.6.1" - form-data "~2.3.2" - har-validator "~5.1.0" - http-signature "~1.2.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.19" - oauth-sign "~0.9.0" - performance-now "^2.1.0" - qs "~6.5.2" - safe-buffer "^5.1.2" - tough-cookie "~2.4.3" - tunnel-agent "^0.6.0" - uuid "^3.3.2" +jsesc@^2.5.1: + version "2.5.2" + resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" + integrity sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA== -require-directory@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" - integrity sha1-jGStX9MNqxyXbiNE/+f3kqam30I= +json-buffer@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.1.tgz#9338802a30d3b6605fbe0613e094008ca8c05a13" + integrity sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ== -require-main-filename@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-1.0.1.tgz#97f717b69d48784f5f526a6c5aa8ffdda055a4d1" - integrity sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE= +json-parse-even-better-errors@^2.3.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" + integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== -require-main-filename@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" - integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== +json-schema-traverse@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660" + integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg== -resolve-cwd@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-2.0.0.tgz#00a9f7387556e27038eae232caa372a6a59b665a" - integrity sha1-AKn3OHVW4nA46uIyyqNypqWbZlo= - dependencies: - resolve-from "^3.0.0" +json-stable-stringify-without-jsonify@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" + integrity sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw== -resolve-from@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" - integrity sha1-six699nWiBvItuZTM17rywoYh0g= +json5@^2.2.3: + version "2.2.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" + integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== -resolve-from@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" - integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== +keyv@^4.5.4: + version "4.5.4" + resolved "https://registry.yarnpkg.com/keyv/-/keyv-4.5.4.tgz#a879a99e29452f942439f2a405e3af8b31d4de93" + integrity sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw== + dependencies: + json-buffer "3.0.1" -resolve-url@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/resolve-url/-/resolve-url-0.2.1.tgz#2c637fe77c893afd2a663fe21aa9080068e2052a" - integrity sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo= +kleur@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" + integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== -resolve@1.1.7: - version "1.1.7" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" - integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= +leven@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" + integrity sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A== -resolve@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.6.0.tgz#0fbd21278b27b4004481c395349e7aba60a9ff5c" - integrity sha512-mw7JQNu5ExIkcw4LPih0owX/TZXjD/ZUF/ZQ/pDnkw3ZKhDcZZw5klmBlj6gVMwjQ3Pz5Jgu7F3d0jcDVuEWdw== +levn@^0.4.1: + version "0.4.1" + resolved "https://registry.yarnpkg.com/levn/-/levn-0.4.1.tgz#ae4562c007473b932a6200d403268dd2fffc6ade" + integrity sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ== dependencies: - path-parse "^1.0.5" + prelude-ls "^1.2.1" + type-check "~0.4.0" -resolve@^1.3.2, resolve@^1.5.0, resolve@^1.9.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.10.0.tgz#3bdaaeaf45cc07f375656dfd2e54ed0810b101ba" - integrity sha512-3sUr9aq5OfSg2S9pNtPA9hL1FVEAjvfOC4leW0SNf/mpnaakz2a9femSd6LqAww2RaFctwyf1lCqnTHuF1rxDg== +lines-and-columns@^1.1.6: + version "1.2.4" + resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" + integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== + +locate-path@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" + integrity sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g== dependencies: - path-parse "^1.0.6" + p-locate "^4.1.0" -restore-cursor@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" - integrity sha1-n37ih/gv0ybU/RYpI9YhKe7g368= +locate-path@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-6.0.0.tgz#55321eb309febbc59c4801d931a72452a681d286" + integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== dependencies: - onetime "^2.0.0" - signal-exit "^3.0.2" + p-locate "^5.0.0" -ret@~0.1.10: - version "0.1.15" - resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" - integrity sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg== +lodash.merge@^4.6.2: + version "4.6.2" + resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" + integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== -rimraf@2.6.3, rimraf@^2.6.2: - version "2.6.3" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.3.tgz#b2d104fe0d8fb27cf9e0a1cda8262dd3833c6cab" - integrity sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA== +lru-cache@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" + integrity sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w== dependencies: - glob "^7.1.3" + yallist "^3.0.2" -rimraf@^2.5.4: - version "2.6.2" - resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" - integrity sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w== +lru-cache@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" + integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== dependencies: - glob "^7.0.5" + yallist "^4.0.0" -rsvp@^3.3.3: - version "3.6.2" - resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-3.6.2.tgz#2e96491599a96cde1b515d5674a8f7a91452926a" - integrity sha512-OfWGQTb9vnwRjwtA2QwpG2ICclHC3pgXZO5xt8H2EfgDquO0qVdSb5T88L4qJVAEugbS56pAuV4XZM58UX8ulw== +make-dir@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-4.0.0.tgz#c3c2307a771277cd9638305f915c29ae741b614e" + integrity sha512-hXdUTZYIVOt1Ex//jAQi+wTZZpUpwBj/0QsOzqegb3rGMMeJiSEu5xLHnYfBrRV4RH2+OCSOO95Is/7x1WJ4bw== + dependencies: + semver "^7.5.3" -run-async@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" - integrity sha1-A3GrSuC91yDUFm19/aZP96RFpsA= +makeerror@1.0.12: + version "1.0.12" + resolved "https://registry.yarnpkg.com/makeerror/-/makeerror-1.0.12.tgz#3e5dd2079a82e812e983cc6610c4a2cb0eaa801a" + integrity sha512-JmqCvUhmt43madlpFzG4BQzG2Z3m6tvQDNKdClZnO3VbIudJYmxsT0FNJMeiB2+JTSlTQTSbU8QdesVmwJcmLg== dependencies: - is-promise "^2.1.0" + tmpl "1.0.5" -rxjs@^6.4.0: - version "6.4.0" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.4.0.tgz#f3bb0fe7bda7fb69deac0c16f17b50b0b8790504" - integrity sha512-Z9Yfa11F6B9Sg/BK9MnqnQ+aQYicPLtilXBp2yUtDt2JRCE0h26d33EnfO3ZxoNxG0T92OUucP3Ct7cpfkdFfw== +merge-stream@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/merge-stream/-/merge-stream-2.0.0.tgz#52823629a14dd00c9770fb6ad47dc6310f2c1f60" + integrity sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w== + +micromatch@^4.0.4: + version "4.0.5" + resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.5.tgz#bc8999a7cbbf77cdc89f132f6e467051b49090c6" + integrity sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA== dependencies: - tslib "^1.9.0" + braces "^3.0.2" + picomatch "^2.3.1" -safe-buffer@^5.0.1, safe-buffer@^5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== +mimic-fn@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-2.1.0.tgz#7ed2c2ccccaf84d3ffcb7a69b57711fc2083401b" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== -safe-regex@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/safe-regex/-/safe-regex-1.1.0.tgz#40a3669f3b077d1e943d44629e157dd48023bf2e" - integrity sha1-QKNmnzsHfR6UPURinhV91IAjvy4= +minimatch@^3.0.4, minimatch@^3.1.1, minimatch@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-3.1.2.tgz#19cd194bfd3e428f049a70817c038d89ab4be35b" + integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: - ret "~0.1.10" + brace-expansion "^1.1.7" + +mri@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mri/-/mri-1.2.0.tgz#6721480fec2a11a4889861115a48b6cbe7cc8f0b" + integrity sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA== -"safer-buffer@>= 2.1.2 < 3": +ms@2.1.2: version "2.1.2" - resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -sane@^4.0.3: - version "4.0.3" - resolved "https://registry.yarnpkg.com/sane/-/sane-4.0.3.tgz#e878c3f19e25cc57fbb734602f48f8a97818b181" - integrity sha512-hSLkC+cPHiBQs7LSyXkotC3UUtyn8C4FMn50TNaacRyvBlI+3ebcxMpqckmTdtXVtel87YS7GXN3UIOj7NiGVQ== - dependencies: - "@cnakazawa/watch" "^1.0.3" - anymatch "^2.0.0" - capture-exit "^1.2.0" - exec-sh "^0.3.2" - execa "^1.0.0" - fb-watchman "^2.0.0" - micromatch "^3.1.4" - minimist "^1.1.1" - walker "~1.0.5" +natural-compare@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" + integrity sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw== -sax@^1.2.4: - version "1.2.4" - resolved "https://registry.yarnpkg.com/sax/-/sax-1.2.4.tgz#2816234e2378bddc4e5354fab5caa895df7100d9" - integrity sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw== +node-int64@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/node-int64/-/node-int64-0.4.0.tgz#87a9065cdb355d3182d8f94ce11188b825c68a3b" + integrity sha512-O5lz91xSOeoXP6DulyHfllpq+Eg00MWitZIbtPfoSEvqIHdl5gfcY6hYzDWnj0qD5tz52PI08u9qUvSVeUBeHw== -"semver@2 || 3 || 4 || 5", semver@^5.4.1, semver@^5.5.0, semver@^5.5.1, semver@~5.6.0: - version "5.6.0" - resolved "https://registry.yarnpkg.com/semver/-/semver-5.6.0.tgz#7e74256fbaa49c75aa7c7a205cc22799cac80004" - integrity sha512-RS9R6R35NYgQn++fkDWaOmqGoj4Ek9gGs+DPxNUZKuwE183xjJroKvyo1IzVFeXvUrvmALy6FWD5xrdJT25gMg== +node-releases@^2.0.13: + version "2.0.13" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-2.0.13.tgz#d5ed1627c23e3461e819b02e57b75e4899b1c81d" + integrity sha512-uYr7J37ae/ORWdZeQ1xxMJe3NtdmqMC/JZK+geofDrkLUApKRHPd18/TxtBOJ4A0/+uUIliorNrfYV6s1b02eQ== -set-blocking@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" - integrity sha1-BF+XgtARrppoA93TgrJDkrPYkPc= +normalize-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== -set-value@^0.4.3: - version "0.4.3" - resolved "https://registry.yarnpkg.com/set-value/-/set-value-0.4.3.tgz#7db08f9d3d22dc7f78e53af3c3bf4666ecdfccf1" - integrity sha1-fbCPnT0i3H945Trzw79GZuzfzPE= +npm-run-path@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.1.tgz#b7ecd1e5ed53da8e37a55e1c2269e0b97ed748ea" + integrity sha512-S48WzZW777zhNIrn7gxOlISNAqi9ZC/uQFnRdbeIHhZhCA6UqpkOT8T1G7BvfdgP4Er8gF4sUbaS0i7QvIfCWw== dependencies: - extend-shallow "^2.0.1" - is-extendable "^0.1.1" - is-plain-object "^2.0.1" - to-object-path "^0.3.0" + path-key "^3.0.0" -set-value@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/set-value/-/set-value-2.0.0.tgz#71ae4a88f0feefbbf52d1ea604f3fb315ebb6274" - integrity sha512-hw0yxk9GT/Hr5yJEYnHNKYXkIA8mVJgd9ditYZCe16ZczcaELYYcfvaXesNACk2O8O0nTiPQcQhGUQj8JLzeeg== +once@^1.3.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== dependencies: - extend-shallow "^2.0.1" - is-extendable "^0.1.1" - is-plain-object "^2.0.3" - split-string "^3.0.1" + wrappy "1" -shebang-command@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-1.2.0.tgz#44aac65b695b03398968c39f363fee5deafdf1ea" - integrity sha1-RKrGW2lbAzmJaMOfNj/uXer98eo= +onetime@^5.1.2: + version "5.1.2" + resolved "https://registry.yarnpkg.com/onetime/-/onetime-5.1.2.tgz#d0e96ebb56b07476df1dd9c4806e5237985ca45e" + integrity sha512-kbpaSSGJTWdAY5KPVeMOKXSrPtr8C8C7wodJbcsd51jRnmD+GZu8Y0VoU6Dm5Z4vWr0Ig/1NKuWRKf7j5aaYSg== dependencies: - shebang-regex "^1.0.0" - -shebang-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" - integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM= + mimic-fn "^2.1.0" -shellwords@^0.1.1: - version "0.1.1" - resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" - integrity sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww== - -signal-exit@^3.0.0, signal-exit@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" - integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= - -sisteransi@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.0.tgz#77d9622ff909080f1c19e5f4a1df0c1b0a27b88c" - integrity sha512-N+z4pHB4AmUv0SjveWRd6q1Nj5w62m5jodv+GD8lvmbY/83T/rpbJGZOnK5T149OldDj4Db07BSv9xY4K6NTPQ== - -slash@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/slash/-/slash-1.0.0.tgz#c41f2f6c39fc16d1cd17ad4b5d896114ae470d55" - integrity sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU= - -slash@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/slash/-/slash-2.0.0.tgz#de552851a1759df3a8f206535442f5ec4ddeab44" - integrity sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A== +optionator@^0.9.3: + version "0.9.3" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.9.3.tgz#007397d44ed1872fdc6ed31360190f81814e2c64" + integrity sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg== + dependencies: + "@aashutoshrathi/word-wrap" "^1.2.3" + deep-is "^0.1.3" + fast-levenshtein "^2.0.6" + levn "^0.4.1" + prelude-ls "^1.2.1" + type-check "^0.4.0" -slice-ansi@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-2.1.0.tgz#cacd7693461a637a5788d92a7dd4fba068e81636" - integrity sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ== +p-limit@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== dependencies: - ansi-styles "^3.2.0" - astral-regex "^1.0.0" - is-fullwidth-code-point "^2.0.0" + p-try "^2.0.0" -snapdragon-node@^2.0.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/snapdragon-node/-/snapdragon-node-2.1.1.tgz#6c175f86ff14bdb0724563e8f3c1b021a286853b" - integrity sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw== +p-limit@^3.0.2, p-limit@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-3.1.0.tgz#e1daccbe78d0d1388ca18c64fea38e3e57e3706b" + integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== dependencies: - define-property "^1.0.0" - isobject "^3.0.0" - snapdragon-util "^3.0.1" + yocto-queue "^0.1.0" -snapdragon-util@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/snapdragon-util/-/snapdragon-util-3.0.1.tgz#f956479486f2acd79700693f6f7b805e45ab56e2" - integrity sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ== - dependencies: - kind-of "^3.2.0" - -snapdragon@^0.8.1: - version "0.8.2" - resolved "https://registry.yarnpkg.com/snapdragon/-/snapdragon-0.8.2.tgz#64922e7c565b0e14204ba1aa7d6964278d25182d" - integrity sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg== - dependencies: - base "^0.11.1" - debug "^2.2.0" - define-property "^0.2.5" - extend-shallow "^2.0.1" - map-cache "^0.2.2" - source-map "^0.5.6" - source-map-resolve "^0.5.0" - use "^3.1.0" - -source-map-resolve@^0.5.0: - version "0.5.2" - resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.2.tgz#72e2cc34095543e43b2c62b2c4c10d4a9054f259" - integrity sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA== - dependencies: - atob "^2.1.1" - decode-uri-component "^0.2.0" - resolve-url "^0.2.1" - source-map-url "^0.4.0" - urix "^0.1.0" - -source-map-support@^0.5.6: - version "0.5.6" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.6.tgz#4435cee46b1aab62b8e8610ce60f788091c51c13" - integrity sha512-N4KXEz7jcKqPf2b2vZF11lQIz9W5ZMuUcIOGj243lduidkf2fjkVKJS9vNxVWn3u/uxX38AcE8U9nnH9FPcq+g== +p-locate@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" + integrity sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A== dependencies: - buffer-from "^1.0.0" - source-map "^0.6.0" + p-limit "^2.2.0" -source-map-url@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/source-map-url/-/source-map-url-0.4.0.tgz#3e935d7ddd73631b97659956d55128e87b5084a3" - integrity sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM= +p-locate@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-5.0.0.tgz#83c8315c6785005e3bd021839411c9e110e6d834" + integrity sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw== + dependencies: + p-limit "^3.0.2" -source-map@^0.5.0, source-map@^0.5.6: - version "0.5.7" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" - integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== -source-map@^0.6.0, source-map@^0.6.1, source-map@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== +parent-module@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" + integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== + dependencies: + callsites "^3.0.0" -spdx-correct@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.0.0.tgz#05a5b4d7153a195bc92c3c425b69f3b2a9524c82" - integrity sha512-N19o9z5cEyc8yQQPukRCZ9EUmb4HUpnrmaL/fxS2pBo2jbfcFRVuFZ/oFC+vZz0MNNk0h80iMn5/S6qGZOL5+g== +parse-json@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" + integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== dependencies: - spdx-expression-parse "^3.0.0" - spdx-license-ids "^3.0.0" + "@babel/code-frame" "^7.0.0" + error-ex "^1.3.1" + json-parse-even-better-errors "^2.3.0" + lines-and-columns "^1.1.6" -spdx-exceptions@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.1.0.tgz#2c7ae61056c714a5b9b9b2b2af7d311ef5c78fe9" - integrity sha512-4K1NsmrlCU1JJgUrtgEeTVyfx8VaYea9J9LvARxhbHtVtohPs/gFGG5yy49beySjlIMhhXZ4QqujIZEfS4l6Cg== +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" + integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== -spdx-expression-parse@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0" - integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== - dependencies: - spdx-exceptions "^2.1.0" - spdx-license-ids "^3.0.0" +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/path-is-absolute/-/path-is-absolute-1.0.1.tgz#174b9268735534ffbc7ace6bf53a5a9e1b5c5f5f" + integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== -spdx-license-ids@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz#7a7cd28470cc6d3a1cfe6d66886f6bc430d3ac87" - integrity sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA== +path-key@^3.0.0, path-key@^3.1.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.1.tgz#581f6ade658cbba65a0d3380de7753295054f375" + integrity sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q== -split-string@^3.0.1, split-string@^3.0.2: - version "3.1.0" - resolved "https://registry.yarnpkg.com/split-string/-/split-string-3.1.0.tgz#7cb09dda3a86585705c64b39a6466038682e8fe2" - integrity sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw== - dependencies: - extend-shallow "^3.0.0" +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== -sprintf-js@~1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" - integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= +picocolors@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" + integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== -sshpk@^1.7.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.14.1.tgz#130f5975eddad963f1d56f92b9ac6c51fa9f83eb" - integrity sha1-Ew9Zde3a2WPx1W+SuaxsUfqfg+s= - dependencies: - asn1 "~0.2.3" - assert-plus "^1.0.0" - dashdash "^1.12.0" - getpass "^0.1.1" - optionalDependencies: - bcrypt-pbkdf "^1.0.0" - ecc-jsbn "~0.1.1" - jsbn "~0.1.0" - tweetnacl "~0.14.0" +picocolors@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.1.1.tgz#3d321af3eab939b083c8f929a1d12cda81c26b6b" + integrity sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA== -stack-utils@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-1.0.1.tgz#d4f33ab54e8e38778b0ca5cfd3b3afb12db68620" - integrity sha1-1PM6tU6OOHeLDKXP07OvsS22hiA= +picomatch@^2.0.4, picomatch@^2.2.3, picomatch@^2.3.1: + version "2.3.1" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" + integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== -static-extend@^0.1.1: - version "0.1.2" - resolved "https://registry.yarnpkg.com/static-extend/-/static-extend-0.1.2.tgz#60809c39cbff55337226fd5e0b520f341f1fb5c6" - integrity sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY= - dependencies: - define-property "^0.2.5" - object-copy "^0.1.0" +picomatch@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-4.0.2.tgz#77c742931e8f3b8820946c76cd0c1f13730d1dab" + integrity sha512-M7BAV6Rlcy5u+m6oPhAPFgJTzAioX/6B0DxyvDlo9l8+T3nLKbrczg2WLUyzd45L8RqfUMyGPzekbMvX2Ldkwg== -stealthy-require@^1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" - integrity sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks= +pirates@^4.0.4: + version "4.0.6" + resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.6.tgz#3018ae32ecfcff6c29ba2267cbf21166ac1f36b9" + integrity sha512-saLsH7WeYYPiD25LDuLRRY/i+6HaPYr6G1OUlN39otzkSTxKnubR9RTxS3/Kk50s1g2JTgFwWQDQyplC5/SHZg== -stream-meter@1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/stream-meter/-/stream-meter-1.0.4.tgz#52af95aa5ea760a2491716704dbff90f73afdd1d" - integrity sha1-Uq+Vql6nYKJJFxZwTb/5D3Ov3R0= +pkg-dir@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/pkg-dir/-/pkg-dir-4.2.0.tgz#f099133df7ede422e81d1d8448270eeb3e4261f3" + integrity sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ== dependencies: - readable-stream "^2.1.4" + find-up "^4.0.0" -string-length@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/string-length/-/string-length-2.0.0.tgz#d40dbb686a3ace960c1cffca562bf2c45f8363ed" - integrity sha1-1A27aGo6zpYMHP/KVivyxF+DY+0= - dependencies: - astral-regex "^1.0.0" - strip-ansi "^4.0.0" +prelude-ls@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" + integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== -string-width@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" - integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= - dependencies: - code-point-at "^1.0.0" - is-fullwidth-code-point "^1.0.0" - strip-ansi "^3.0.0" +prettier@^3.5.3: + version "3.5.3" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.5.3.tgz#4fc2ce0d657e7a02e602549f053b239cb7dfe1b5" + integrity sha512-QQtaxnoDJeAkDvDKWCLiwIXkTgRhwYDEQCghU9Z6q03iyek/rxRh/2lC3HB7P8sWT2xC/y5JDctPLBIGzHKbhw== -string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: - version "2.1.1" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" - integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== +pretty-format@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-29.7.0.tgz#ca42c758310f365bfa71a0bda0a807160b776812" + integrity sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ== dependencies: - is-fullwidth-code-point "^2.0.0" - strip-ansi "^4.0.0" + "@jest/schemas" "^29.6.3" + ansi-styles "^5.0.0" + react-is "^18.0.0" -string-width@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.0.0.tgz#5a1690a57cc78211fffd9bf24bbe24d090604eb1" - integrity sha512-rr8CUxBbvOZDUvc5lNIJ+OC1nPVpz+Siw9VBtUjB9b6jZehZLFt0JMCZzShFHIsI8cbhm0EsNIfWJMFV3cu3Ew== +pretty-quick@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/pretty-quick/-/pretty-quick-4.1.1.tgz#8a0c883e4beeb0eddbe7eda50d7b1251d4f72968" + integrity sha512-9Ud0l/CspNTmyIdYac9X7Inb3o8fuUsw+1zJFvCGn+at0t1UwUcUdo2RSZ41gcmfLv1fxgWQxWEfItR7CBwugg== dependencies: - emoji-regex "^7.0.1" - is-fullwidth-code-point "^2.0.0" - strip-ansi "^5.0.0" + find-up "^5.0.0" + ignore "^7.0.3" + mri "^1.2.0" + picocolors "^1.1.1" + picomatch "^4.0.2" + tinyexec "^0.3.2" + tslib "^2.8.1" -string_decoder@~1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" - integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== +prompts@^2.0.1: + version "2.4.2" + resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.4.2.tgz#7b57e73b3a48029ad10ebd44f74b01722a4cb069" + integrity sha512-NxNv/kLguCA7p3jE8oL2aEBsrJWgAakBpgmgK6lpPWV+WuOmY6r2/zbAVnP+T8bQlA0nzHXSJSJW0Hq7ylaD2Q== dependencies: - safe-buffer "~5.1.0" + kleur "^3.0.3" + sisteransi "^1.0.5" -strip-ansi@^3.0.0, strip-ansi@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" - integrity sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8= - dependencies: - ansi-regex "^2.0.0" +punycode@^2.1.0: + version "2.3.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" + integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== -strip-ansi@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-4.0.0.tgz#a8479022eb1ac368a871389b635262c505ee368f" - integrity sha1-qEeQIusaw2iocTibY1JixQXuNo8= - dependencies: - ansi-regex "^3.0.0" +pure-rand@^6.0.0: + version "6.0.4" + resolved "https://registry.yarnpkg.com/pure-rand/-/pure-rand-6.0.4.tgz#50b737f6a925468679bff00ad20eade53f37d5c7" + integrity sha512-LA0Y9kxMYv47GIPJy6MI84fqTd2HmYZI83W/kM/SkKfDlajnZYfmXFTxkbY+xSBPkLJxltMa9hIkmdc29eguMA== -strip-ansi@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.0.0.tgz#f78f68b5d0866c20b2c9b8c61b5298508dc8756f" - integrity sha512-Uu7gQyZI7J7gn5qLn1Np3G9vcYGTVqB+lFTytnDJv83dd8T22aGH451P3jueT2/QemInJDfxHB5Tde5OzgG1Ow== - dependencies: - ansi-regex "^4.0.0" +react-is@^18.0.0: + version "18.2.0" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.2.0.tgz#199431eeaaa2e09f86427efbb4f1473edb47609b" + integrity sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w== + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== -strip-bom@^3.0.0: +resolve-cwd@^3.0.0: version "3.0.0" - resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-3.0.0.tgz#2334c18e9c759f7bdd56fdef7e9ae3d588e68ed3" - integrity sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM= + resolved "https://registry.yarnpkg.com/resolve-cwd/-/resolve-cwd-3.0.0.tgz#0f0075f1bb2544766cf73ba6a6e2adfebcb13f2d" + integrity sha512-OrZaX2Mb+rJCpH/6CpSqt9xFVpN++x01XnN2ie9g6P5/3xelLAkXWVADpdz1IHD/KFfEXyE6V0U01OQ3UO2rEg== + dependencies: + resolve-from "^5.0.0" -strip-eof@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/strip-eof/-/strip-eof-1.0.0.tgz#bb43ff5598a6eb05d89b59fcd129c983313606bf" - integrity sha1-u0P/VZim6wXYm1n80SnJgzE2Br8= +resolve-from@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" + integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== -strip-json-comments@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" - integrity sha1-PFMZQukIwml8DsNEhYwobHygpgo= +resolve-from@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-5.0.0.tgz#c35225843df8f776df21c57557bc087e9dfdfc69" + integrity sha512-qYg9KP24dD5qka9J47d0aVky0N+b4fTU89LN9iDnjB5waksiC49rvMB0PrUJQGoTmH50XPiqOvAjDfaijGxYZw== -supports-color@^5.3.0: - version "5.4.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.4.0.tgz#1c6b337402c2137605efe19f10fec390f6faab54" - integrity sha512-zjaXglF5nnWpsq470jSv6P9DwPvgLkuapYmfDm3JWOm0vkNTVF2tI4UrN2r6jH1qM/uc/WtxYY1hYoA2dOKj5w== - dependencies: - has-flag "^3.0.0" +resolve.exports@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/resolve.exports/-/resolve.exports-2.0.2.tgz#f8c934b8e6a13f539e38b7098e2e36134f01e800" + integrity sha512-X2UW6Nw3n/aMgDVy+0rSqgHlv39WZAlZrXCdnbyEiKm17DSqHX4MmQMaST3FbeWR5FTuRcUwYAziZajji0Y7mg== -supports-color@^6.0.0, supports-color@^6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-6.1.0.tgz#0764abc69c63d5ac842dd4867e8d025e880df8f3" - integrity sha512-qe1jfm1Mg7Nq/NSh6XE24gPXROEVsWHxC1LIx//XNlD9iw7YZQGjZNjYN7xGaEG6iKdA8EtNFW6R0gjnVXp+wQ== +resolve@^1.20.0: + version "1.22.8" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.22.8.tgz#b6c87a9f2aa06dfab52e3d70ac8cde321fa5a48d" + integrity sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw== dependencies: - has-flag "^3.0.0" + is-core-module "^2.13.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" -symbol-tree@^3.2.2: - version "3.2.2" - resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6" - integrity sha1-rifbOPZgp64uHDt9G8KQgZuFGeY= +semver@^6.3.0, semver@^6.3.1: + version "6.3.1" + resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" + integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -table@^5.2.3: - version "5.2.3" - resolved "https://registry.yarnpkg.com/table/-/table-5.2.3.tgz#cde0cc6eb06751c009efab27e8c820ca5b67b7f2" - integrity sha512-N2RsDAMvDLvYwFcwbPyF3VmVSSkuF+G1e+8inhBLtHpvwXGw4QRPEZhihQNeEN0i1up6/f6ObCJXNdlRG3YVyQ== +semver@^7.5.3, semver@^7.5.4: + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== dependencies: - ajv "^6.9.1" - lodash "^4.17.11" - slice-ansi "^2.1.0" - string-width "^3.0.0" + lru-cache "^6.0.0" -test-exclude@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-5.0.0.tgz#cdce7cece785e0e829cd5c2b27baf18bc583cfb7" - integrity sha512-bO3Lj5+qFa9YLfYW2ZcXMOV1pmQvw+KS/DpjqhyX6Y6UZ8zstpZJ+mA2ERkXfpOqhxsJlQiLeVXD3Smsrs6oLw== +shebang-command@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea" + integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA== dependencies: - arrify "^1.0.1" - minimatch "^3.0.4" - read-pkg-up "^4.0.0" - require-main-filename "^1.0.1" + shebang-regex "^3.0.0" -text-table@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/text-table/-/text-table-0.2.0.tgz#7f5ee823ae805207c00af2df4a84ec3fcfa570b4" - integrity sha1-f17oI66AUgfACvLfSoTsP8+lcLQ= +shebang-regex@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172" + integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A== -throat@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/throat/-/throat-4.1.0.tgz#89037cbc92c56ab18926e6ba4cbb200e15672a6a" - integrity sha1-iQN8vJLFarGJJua6TLsgDhVnKmo= +signal-exit@^3.0.3, signal-exit@^3.0.7: + version "3.0.7" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" + integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== -throttleit@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/throttleit/-/throttleit-1.0.0.tgz#9e785836daf46743145a5984b6268d828528ac6c" - integrity sha1-nnhYNtr0Z0MUWlmEtiaNgoUorGw= +sisteransi@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed" + integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg== -through@^2.3.6: - version "2.3.8" - resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" - integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= +slash@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/slash/-/slash-3.0.0.tgz#6539be870c165adbd5240220dbe361f1bc4d4634" + integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== -tmp@^0.0.33: - version "0.0.33" - resolved "https://registry.yarnpkg.com/tmp/-/tmp-0.0.33.tgz#6d34335889768d21b2bcda0aa277ced3b1bfadf9" - integrity sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw== +source-map-support@0.5.13: + version "0.5.13" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.13.tgz#31b24a9c2e73c2de85066c0feb7d44767ed52932" + integrity sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w== dependencies: - os-tmpdir "~1.0.2" - -tmpl@1.0.x: - version "1.0.4" - resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.4.tgz#23640dd7b42d00433911140820e5cf440e521dd1" - integrity sha1-I2QN17QtAEM5ERQIIOXPRA5SHdE= + buffer-from "^1.0.0" + source-map "^0.6.0" -to-fast-properties@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4= +source-map@^0.6.0, source-map@^0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" + integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== -to-object-path@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af" - integrity sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68= - dependencies: - kind-of "^3.0.2" +sprintf-js@~1.0.2: + version "1.0.3" + resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" + integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== -to-regex-range@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-2.1.1.tgz#7c80c17b9dfebe599e27367e0d4dd5590141db38" - integrity sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg= +stack-utils@^2.0.3: + version "2.0.6" + resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-2.0.6.tgz#aaf0748169c02fc33c8232abccf933f54a1cc34f" + integrity sha512-XlkWvfIm6RmsWtNJx+uqtKLS8eqFbxUg0ZzLXqY0caEy9l7hruX8IpiDnjsLavoBgqCCR71TqWO8MaXYheJ3RQ== dependencies: - is-number "^3.0.0" - repeat-string "^1.6.1" + escape-string-regexp "^2.0.0" -to-regex@^3.0.1, to-regex@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/to-regex/-/to-regex-3.0.2.tgz#13cfdd9b336552f30b51f33a8ae1b42a7a7599ce" - integrity sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw== +string-length@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/string-length/-/string-length-4.0.2.tgz#a8a8dc7bd5c1a82b9b3c8b87e125f66871b6e57a" + integrity sha512-+l6rNN5fYHNhZZy41RXsYptCjA2Igmq4EG7kZAYFQI1E1VTXarr6ZPXBg6eq7Y6eK4FEhY6AJlyuFIb/v/S0VQ== dependencies: - define-property "^2.0.2" - extend-shallow "^3.0.2" - regex-not "^1.0.2" - safe-regex "^1.1.0" + char-regex "^1.0.2" + strip-ansi "^6.0.0" -tough-cookie@>=2.3.3, tough-cookie@^2.3.3: - version "2.3.4" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655" - integrity sha512-TZ6TTfI5NtZnuyy/Kecv+CnoROnyXn2DN97LontgQpCwsX2XyLYCC0ENhYkehSOwAp8rTQKc/NUIF7BkQ5rKLA== +string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3: + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== dependencies: - punycode "^1.4.1" + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" -tough-cookie@~2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" - integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== dependencies: - psl "^1.1.24" - punycode "^1.4.1" + ansi-regex "^5.0.1" -tr46@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" - integrity sha1-qLE/1r/SSJUZZ0zN5VujaTtwbQk= - dependencies: - punycode "^2.1.0" +strip-bom@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-4.0.0.tgz#9c3505c1db45bcedca3d9cf7a16f5c5aa3901878" + integrity sha512-3xurFv5tEgii33Zi8Jtp55wEIILR9eh34FAW00PZf+JnSsTmV/ioewSgQl97JHvgjoRGwPShsWm+IdrxB35d0w== -trim-right@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" - integrity sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM= +strip-final-newline@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strip-final-newline/-/strip-final-newline-2.0.0.tgz#89b852fb2fcbe936f6f4b3187afb0a12c1ab58ad" + integrity sha512-BrpvfNAE3dcvq7ll3xVumzjKjZQ5tI1sEUIKr3Uoks0XUl45St3FlatVqef9prk4jRDzhW6WZg+3bk93y6pLjA== -tslib@^1.9.0: - version "1.9.3" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" - integrity sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ== +strip-json-comments@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" + integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== -tunnel-agent@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" - integrity sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0= +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: - safe-buffer "^5.0.1" - -tweetnacl@^0.14.3, tweetnacl@~0.14.0: - version "0.14.5" - resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" - integrity sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q= + has-flag "^3.0.0" -type-check@~0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.3.2.tgz#5884cab512cf1d355e3fb784f30804b2b520db72" - integrity sha1-WITKtRLPHTVeP7eE8wgEsrUg23I= +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== dependencies: - prelude-ls "~1.1.2" + has-flag "^4.0.0" -uglify-js@^3.1.4: - version "3.4.9" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.4.9.tgz#af02f180c1207d76432e473ed24a28f4a782bae3" - integrity sha512-8CJsbKOtEbnJsTyv6LE6m6ZKniqMiFWmm9sRbopbkGs3gMPPfd3Fh8iIA4Ykv5MgaTbqHr4BaoGLJLZNhsrW1Q== +supports-color@^8.0.0: + version "8.1.1" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" + integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== dependencies: - commander "~2.17.1" - source-map "~0.6.1" + has-flag "^4.0.0" -uid2@0.0.3: - version "0.0.3" - resolved "https://registry.yarnpkg.com/uid2/-/uid2-0.0.3.tgz#483126e11774df2f71b8b639dcd799c376162b82" - integrity sha1-SDEm4Rd03y9xuLY53NeZw3YWK4I= - -union-value@^1.0.0: +supports-preserve-symlinks-flag@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/union-value/-/union-value-1.0.0.tgz#5c71c34cb5bad5dcebe3ea0cd08207ba5aa1aea4" - integrity sha1-XHHDTLW61dzr4+oM0IIHulqhrqQ= - dependencies: - arr-union "^3.1.0" - get-value "^2.0.6" - is-extendable "^0.1.1" - set-value "^0.4.3" + resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" + integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== -unique-temp-dir@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/unique-temp-dir/-/unique-temp-dir-1.0.0.tgz#6dce95b2681ca003eebfb304a415f9cbabcc5385" - integrity sha1-bc6VsmgcoAPuv7MEpBX5y6vMU4U= +test-exclude@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-6.0.0.tgz#04a8698661d805ea6fa293b6cb9e63ac044ef15e" + integrity sha512-cAGWPIyOHU6zlmg88jwm7VRyXnMN7iV68OGAbYDk/Mh/xC/pzVPlQtY6ngoIH/5/tciuhGfvESU8GrHrcxD56w== dependencies: - mkdirp "^0.5.1" - os-tmpdir "^1.0.1" - uid2 "0.0.3" - -universalify@^0.1.0: - version "0.1.2" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" - integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== + "@istanbuljs/schema" "^0.1.2" + glob "^7.1.4" + minimatch "^3.0.4" -unset-value@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/unset-value/-/unset-value-1.0.0.tgz#8376873f7d2335179ffb1e6fc3a8ed0dfc8ab559" - integrity sha1-g3aHP30jNRef+x5vw6jtDfyKtVk= - dependencies: - has-value "^0.3.1" - isobject "^3.0.0" +tinyexec@^0.3.2: + version "0.3.2" + resolved "https://registry.yarnpkg.com/tinyexec/-/tinyexec-0.3.2.tgz#941794e657a85e496577995c6eef66f53f42b3d2" + integrity sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA== -uri-js@^4.2.2: - version "4.2.2" - resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.2.2.tgz#94c540e1ff772956e2299507c010aea6c8838eb0" - integrity sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ== - dependencies: - punycode "^2.1.0" +tmpl@1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/tmpl/-/tmpl-1.0.5.tgz#8683e0b902bb9c20c4f726e3c0b69f36518c07cc" + integrity sha512-3f0uOEAQwIqGuWW2MVzYg8fV/QNnc/IpuJNG837rLuczAaLVHslWHZQj4IGiEl5Hs3kkbhwL9Ab7Hrsmuj+Smw== -urix@^0.1.0: - version "0.1.0" - resolved "https://registry.yarnpkg.com/urix/-/urix-0.1.0.tgz#da937f7a62e21fec1fd18d49b35c2935067a6c72" - integrity sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI= +to-fast-properties@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" + integrity sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog== -use@^3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/use/-/use-3.1.0.tgz#14716bf03fdfefd03040aef58d8b4b85f3a7c544" - integrity sha512-6UJEQM/L+mzC3ZJNM56Q4DFGLX/evKGRg15UJHGB9X5j5Z3AFbgZvjUh2yq/UJUY4U5dh7Fal++XbNg1uzpRAw== +to-regex-range@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/to-regex-range/-/to-regex-range-5.0.1.tgz#1648c44aae7c8d988a326018ed72f5b4dd0392e4" + integrity sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ== dependencies: - kind-of "^6.0.2" + is-number "^7.0.0" -util-deprecate@~1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" - integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= +tslib@^2.8.1: + version "2.8.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.8.1.tgz#612efe4ed235d567e8aba5f2a5fab70280ade83f" + integrity sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w== -util.promisify@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.0.tgz#440f7165a459c9a16dc145eb8e72f35687097030" - integrity sha512-i+6qA2MPhvoKLuxnJNpXAGhg7HphQOSUq2LKMZD0m15EiskXUkMvKdF4Uui0WYeCUGea+o2cw/ZuwehtfsrNkA== +type-check@^0.4.0, type-check@~0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/type-check/-/type-check-0.4.0.tgz#07b8203bfa7056c0657050e3ccd2c37730bab8f1" + integrity sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew== dependencies: - define-properties "^1.1.2" - object.getownpropertydescriptors "^2.0.3" + prelude-ls "^1.2.1" -uuid@^3.3.2: - version "3.3.2" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.2.tgz#1b4af4955eb3077c501c23872fc6513811587131" - integrity sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA== +type-detect@4.0.8: + version "4.0.8" + resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" + integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== -validate-npm-package-license@^3.0.1: - version "3.0.3" - resolved "https://registry.yarnpkg.com/validate-npm-package-license/-/validate-npm-package-license-3.0.3.tgz#81643bcbef1bdfecd4623793dc4648948ba98338" - integrity sha512-63ZOUnL4SIXj4L0NixR3L1lcjO38crAbgrTpl28t8jjrfuiOBL5Iygm+60qPs/KsZGzPNg6Smnc/oY16QTjF0g== - dependencies: - spdx-correct "^3.0.0" - spdx-expression-parse "^3.0.0" +type-fest@^0.21.3: + version "0.21.3" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.21.3.tgz#d260a24b0198436e133fa26a524a6d65fa3b2e37" + integrity sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w== -verror@1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" - integrity sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA= - dependencies: - assert-plus "^1.0.0" - core-util-is "1.0.2" - extsprintf "^1.2.0" +undici-types@~5.26.4: + version "5.26.5" + resolved "https://registry.yarnpkg.com/undici-types/-/undici-types-5.26.5.tgz#bcd539893d00b56e964fd2657a4866b221a65617" + integrity sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA== -w3c-hr-time@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz#82ac2bff63d950ea9e3189a58a65625fedf19045" - integrity sha1-gqwr/2PZUOqeMYmlimViX+3xkEU= +update-browserslist-db@^1.0.13: + version "1.0.13" + resolved "https://registry.yarnpkg.com/update-browserslist-db/-/update-browserslist-db-1.0.13.tgz#3c5e4f5c083661bd38ef64b6328c26ed6c8248c4" + integrity sha512-xebP81SNcPuNpPP3uzeW1NYXxI3rxyJzF3pD6sH4jE7o/IX+WtSpwnVU+qIsDPyk0d3hmFQ7mjqc6AtV604hbg== dependencies: - browser-process-hrtime "^0.1.2" + escalade "^3.1.1" + picocolors "^1.0.0" -walker@~1.0.5: - version "1.0.7" - resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.7.tgz#2f7f9b8fd10d677262b18a884e28d19618e028fb" - integrity sha1-L3+bj9ENZ3JisYqITijRlhjgKPs= +uri-js@^4.2.2: + version "4.4.1" + resolved "https://registry.yarnpkg.com/uri-js/-/uri-js-4.4.1.tgz#9b1a52595225859e55f669d928f88c6c57f2a77e" + integrity sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg== dependencies: - makeerror "1.0.x" - -webidl-conversions@^4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" - integrity sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg== + punycode "^2.1.0" -whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/whatwg-encoding/-/whatwg-encoding-1.0.3.tgz#57c235bc8657e914d24e1a397d3c82daee0a6ba3" - integrity sha512-jLBwwKUhi8WtBfsMQlL4bUUcT8sMkAtQinscJAe/M4KHCkHuUJAF6vuB0tueNIw4c8ziO6AkRmgY+jL3a0iiPw== +v8-to-istanbul@^9.0.1: + version "9.1.3" + resolved "https://registry.yarnpkg.com/v8-to-istanbul/-/v8-to-istanbul-9.1.3.tgz#ea456604101cd18005ac2cae3cdd1aa058a6306b" + integrity sha512-9lDD+EVI2fjFsMWXc6dy5JJzBsVTcQ2fVkfBvncZ6xJWG9wtBhOldG+mHkSL0+V1K/xgZz0JDO5UT5hFwHUghg== dependencies: - iconv-lite "0.4.19" + "@jridgewell/trace-mapping" "^0.3.12" + "@types/istanbul-lib-coverage" "^2.0.1" + convert-source-map "^2.0.0" -whatwg-mimetype@^2.0.0, whatwg-mimetype@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-2.1.0.tgz#f0f21d76cbba72362eb609dbed2a30cd17fcc7d4" - integrity sha512-FKxhYLytBQiUKjkYteN71fAUA3g6KpNXoho1isLiLSB3N1G4F35Q5vUxWfKFhBwi5IWF27VE6WxhrnnC+m0Mew== - -whatwg-url@^6.4.0, whatwg-url@^6.4.1: - version "6.4.1" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.1.tgz#fdb94b440fd4ad836202c16e9737d511f012fd67" - integrity sha512-FwygsxsXx27x6XXuExA/ox3Ktwcbf+OAvrKmLulotDAiO1Q6ixchPFaHYsis2zZBZSJTR0+dR+JVtf7MlbqZjw== +walker@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.8.tgz#bd498db477afe573dc04185f011d3ab8a8d7653f" + integrity sha512-ts/8E8l5b7kY0vlWLewOkDXMmPdLcVV4GmOQLyxuSswIJsweeFZtAsMF7k1Nszz+TYBQrlYRmzOnr398y1JemQ== dependencies: - lodash.sortby "^4.7.0" - tr46 "^1.0.1" - webidl-conversions "^4.0.2" - -which-module@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" - integrity sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho= + makeerror "1.0.12" -which@^1.2.9, which@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" - integrity sha512-xcJpopdamTuY5duC/KnTTNBraPK54YwpenP4lzxU8H91GudWpFv38u0CKjclE1Wi2EH2EDz5LRcHcKbCIzqGyg== +which@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/which/-/which-2.0.2.tgz#7c6a8dd0a636a0327e10b59c9286eee93f3f51b1" + integrity sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA== dependencies: isexe "^2.0.0" -wordwrap@~0.0.2: - version "0.0.3" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" - integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= - -wordwrap@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= - -wrap-ansi@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-2.1.0.tgz#d8fc3d284dd05794fe84973caecdd1cf824fdd85" - integrity sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU= +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" wrappy@1: version "1.0.2" resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" - integrity sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8= + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== -write-file-atomic@2.4.1: - version "2.4.1" - resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-2.4.1.tgz#d0b05463c188ae804396fd5ab2a370062af87529" - integrity sha512-TGHFeZEZMnv+gBFRfjAcxL5bPHrsGKtnb4qsFAws7/vlh+QfwAaySIw4AXP9ZskTTh5GWu3FLuJhsWVdiJPGvg== +write-file-atomic@^4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-4.0.2.tgz#a9df01ae5b77858a027fd2e80768ee433555fcfd" + integrity sha512-7KxauUdBmSdWnmpaGFg+ppNjKF8uNLry8LyzjauQDOVONfFLNKrKvQOxZ/VuTIcS/gge/YNahf5RIIQWTSarlg== dependencies: - graceful-fs "^4.1.11" imurmurhash "^0.1.4" - signal-exit "^3.0.2" - -write@1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/write/-/write-1.0.3.tgz#0800e14523b923a387e415123c865616aae0f5c3" - integrity sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig== - dependencies: - mkdirp "^0.5.1" + signal-exit "^3.0.7" -ws@^4.0.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-4.1.0.tgz#a979b5d7d4da68bf54efe0408967c324869a7289" - integrity sha512-ZGh/8kF9rrRNffkLFV4AzhvooEclrOH0xaugmqGsIfFgOE/pIz4fMc4Ef+5HSQqTEug2S9JZIWDR47duDSLfaA== - dependencies: - async-limiter "~1.0.0" - safe-buffer "~5.1.0" +y18n@^5.0.5: + version "5.0.8" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55" + integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== -xml-name-validator@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/xml-name-validator/-/xml-name-validator-3.0.0.tgz#6ae73e06de4d8c6e47f9fb181f78d648ad457c6a" - integrity sha512-A5CUptxDsvxKJEU3yO6DuWBSJz/qizqzJKOMIfUJHETbBw/sFaDxgd6fxm1ewUaM0jZ444Fc5vC5ROYurg/4Pw== +yallist@^3.0.2: + version "3.1.1" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" + integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== -"y18n@^3.2.1 || ^4.0.0", y18n@^4.0.0: +yallist@^4.0.0: version "4.0.0" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.0.tgz#95ef94f85ecc81d007c264e190a120f0a3c8566b" - integrity sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w== - -yargs-parser@^11.1.1: - version "11.1.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-11.1.1.tgz#879a0865973bca9f6bab5cbdf3b1c67ec7d3bcf4" - integrity sha512-C6kB/WJDiaxONLJQnF8ccx9SEeoTTLek8RVbaOIsrAUS8VrBEXfmeSnCZxygc+XC2sNMBIwOOnfcxiynjHsVSQ== - dependencies: - camelcase "^5.0.0" - decamelize "^1.2.0" - -yargs-parser@^13.0.0: - version "13.0.0" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.0.0.tgz#3fc44f3e76a8bdb1cc3602e860108602e5ccde8b" - integrity sha512-w2LXjoL8oRdRQN+hOyppuXs+V/fVAYtpcrRxZuF7Kt/Oc+Jr2uAcVntaUTNT6w5ihoWfFDpNY8CPx1QskxZ/pw== - dependencies: - camelcase "^5.0.0" - decamelize "^1.2.0" - -yargs@^12.0.2: - version "12.0.5" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.5.tgz#05f5997b609647b64f66b81e3b4b10a368e7ad13" - integrity sha512-Lhz8TLaYnxq/2ObqHDql8dX8CJi97oHxrjUcYtzKbbykPtVW9WB+poxI+NM2UIzsMgNCZTIf0AQwsjK5yMAqZw== - dependencies: - cliui "^4.0.0" - decamelize "^1.2.0" - find-up "^3.0.0" - get-caller-file "^1.0.1" - os-locale "^3.0.0" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^2.0.0" - which-module "^2.0.0" - y18n "^3.2.1 || ^4.0.0" - yargs-parser "^11.1.1" - -yargs@^13.1.0: - version "13.2.1" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.2.1.tgz#c8888bcf24424bd4e5a834348366f6fcc37bb8d9" - integrity sha512-HgY0xHGmPPakg6kEDufqxZuXVtvPZcipORC8O7S44iEnwsUmP+qnhReHc6d1dyeIZkrPmYFblh45Z2oeDn++fQ== - dependencies: - cliui "^4.0.0" - find-up "^3.0.0" - get-caller-file "^2.0.1" - os-locale "^3.1.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== + +yargs-parser@^21.1.1: + version "21.1.1" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-21.1.1.tgz#9096bceebf990d21bb31fa9516e0ede294a77d35" + integrity sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw== + +yargs@^17.3.1: + version "17.7.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-17.7.2.tgz#991df39aca675a192b816e1e0363f9d75d2aa269" + integrity sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w== + dependencies: + cliui "^8.0.1" + escalade "^3.1.1" + get-caller-file "^2.0.5" require-directory "^2.1.1" - require-main-filename "^2.0.0" - set-blocking "^2.0.0" - string-width "^3.0.0" - which-module "^2.0.0" - y18n "^4.0.0" - yargs-parser "^13.0.0" + string-width "^4.2.3" + y18n "^5.0.5" + yargs-parser "^21.1.1" + +yocto-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-0.1.0.tgz#0294eb3dee05028d31ee1a5fa2c556a6aaf10a1b" + integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==