vitest 0.24.5 → 0.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/LICENSE.md +286 -57
  2. package/dist/browser.d.ts +3 -3
  3. package/dist/browser.js +17 -10
  4. package/dist/{chunk-api-setup.629f8133.js → chunk-api-setup.a13c5f9d.js} +38 -19
  5. package/dist/{chunk-install-pkg.22707ee4.js → chunk-install-pkg.55bfe508.js} +4 -5
  6. package/dist/{chunk-integrations-coverage.cca09977.js → chunk-integrations-coverage.befed097.js} +57 -1
  7. package/dist/chunk-integrations-globals.391b3839.js +25 -0
  8. package/dist/{chunk-node-git.82174cfe.js → chunk-node-git.af5c9d73.js} +5 -6
  9. package/dist/{chunk-runtime-chain.37ec5d73.js → chunk-runtime-chain.3b531731.js} +27 -23
  10. package/dist/{chunk-runtime-error.17751c39.js → chunk-runtime-error.3cc15c6f.js} +9 -2
  11. package/dist/{chunk-runtime-mocker.41b92ec9.js → chunk-runtime-mocker.a5d87666.js} +4 -4
  12. package/dist/{chunk-runtime-rpc.b418c0ab.js → chunk-runtime-rpc.4a2d45ab.js} +2 -2
  13. package/dist/chunk-runtime-setup.f644ac4c.js +1350 -0
  14. package/dist/{chunk-runtime-hooks.d748b085.js → chunk-runtime-test-state.31ce8643.js} +106 -6
  15. package/dist/{chunk-mock-date.030959d3.js → chunk-typecheck-constants.410fa7b2.js} +23 -4
  16. package/dist/{chunk-utils-env.b1281522.js → chunk-utils-env.7fe285cc.js} +2 -0
  17. package/dist/chunk-utils-source-map.1a66263d.js +90 -0
  18. package/dist/{chunk-utils-timers.8fca243e.js → chunk-utils-timers.d1fcc6bb.js} +86 -79
  19. package/dist/{chunk-vite-node-client.3868b3ba.js → chunk-vite-node-client.13ea0a59.js} +25 -5
  20. package/dist/{chunk-vite-node-externalize.d9033432.js → chunk-vite-node-externalize.01d0d22c.js} +821 -92
  21. package/dist/chunk-vite-node-utils.b89230f3.js +1400 -0
  22. package/dist/cli-wrapper.js +5 -6
  23. package/dist/cli.js +27 -13
  24. package/dist/config.cjs +6 -1
  25. package/dist/config.d.ts +6 -1
  26. package/dist/config.js +6 -1
  27. package/dist/entry.js +11 -10
  28. package/dist/environments.d.ts +1 -1
  29. package/dist/index-b68b3c09.d.ts +256 -0
  30. package/dist/index.d.ts +4 -4
  31. package/dist/index.js +13 -7
  32. package/dist/loader.js +4 -3
  33. package/dist/node.d.ts +2 -2
  34. package/dist/node.js +18 -11
  35. package/dist/suite.js +6 -6
  36. package/dist/{global-58e8e951.d.ts → types-b3ff5eea.d.ts} +215 -18
  37. package/dist/{vendor-index.cc8d244b.js → vendor-index.16d769d7.js} +1 -2
  38. package/dist/{vendor-index.12d51d29.js → vendor-index.22806ffb.js} +279 -7
  39. package/dist/{vendor-index.9c919048.js → vendor-index.808a85a6.js} +0 -0
  40. package/dist/worker.js +9 -8
  41. package/globals.d.ts +2 -0
  42. package/package.json +13 -9
  43. package/dist/chunk-integrations-globals.32ef80c3.js +0 -25
  44. package/dist/chunk-runtime-setup.ab6b6274.js +0 -676
  45. package/dist/chunk-utils-source-map.663e2952.js +0 -3429
  46. package/dist/chunk-vite-node-utils.2144000e.js +0 -6946
  47. package/dist/index-220c1d70.d.ts +0 -117
  48. package/dist/vendor-index.1a291e86.js +0 -275
package/LICENSE.md CHANGED
@@ -197,35 +197,6 @@ Repository: https://github.com/sinonjs/fake-timers.git
197
197
 
198
198
  ---------------------------------------
199
199
 
200
- ## acorn
201
- License: MIT
202
- By: Marijn Haverbeke, Ingvar Stepanyan, Adrian Heine
203
- Repository: https://github.com/acornjs/acorn.git
204
-
205
- > MIT License
206
- >
207
- > Copyright (C) 2012-2022 by various contributors (see AUTHORS)
208
- >
209
- > Permission is hereby granted, free of charge, to any person obtaining a copy
210
- > of this software and associated documentation files (the "Software"), to deal
211
- > in the Software without restriction, including without limitation the rights
212
- > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
213
- > copies of the Software, and to permit persons to whom the Software is
214
- > furnished to do so, subject to the following conditions:
215
- >
216
- > The above copyright notice and this permission notice shall be included in
217
- > all copies or substantial portions of the Software.
218
- >
219
- > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
220
- > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
221
- > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
222
- > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
223
- > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
224
- > OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
225
- > THE SOFTWARE.
226
-
227
- ---------------------------------------
228
-
229
200
  ## ansi-escapes
230
201
  License: MIT
231
202
  By: Sindre Sorhus
@@ -335,6 +306,34 @@ Repository: micromatch/braces
335
306
 
336
307
  ---------------------------------------
337
308
 
309
+ ## buffer-from
310
+ License: MIT
311
+ Repository: LinusU/buffer-from
312
+
313
+ > MIT License
314
+ >
315
+ > Copyright (c) 2016, 2018 Linus Unnebäck
316
+ >
317
+ > Permission is hereby granted, free of charge, to any person obtaining a copy
318
+ > of this software and associated documentation files (the "Software"), to deal
319
+ > in the Software without restriction, including without limitation the rights
320
+ > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
321
+ > copies of the Software, and to permit persons to whom the Software is
322
+ > furnished to do so, subject to the following conditions:
323
+ >
324
+ > The above copyright notice and this permission notice shall be included in all
325
+ > copies or substantial portions of the Software.
326
+ >
327
+ > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
328
+ > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
329
+ > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
330
+ > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
331
+ > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
332
+ > OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
333
+ > SOFTWARE.
334
+
335
+ ---------------------------------------
336
+
338
337
  ## cac
339
338
  License: MIT
340
339
  By: egoist
@@ -575,6 +574,214 @@ Repository: sindresorhus/execa
575
574
 
576
575
  ---------------------------------------
577
576
 
577
+ ## expect-type
578
+ License: Apache-2.0
579
+ Repository: https://github.com/mmkal/expect-type.git
580
+
581
+ > Apache License
582
+ > Version 2.0, January 2004
583
+ > http://www.apache.org/licenses/
584
+ >
585
+ > TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
586
+ >
587
+ > 1. Definitions.
588
+ >
589
+ > "License" shall mean the terms and conditions for use, reproduction,
590
+ > and distribution as defined by Sections 1 through 9 of this document.
591
+ >
592
+ > "Licensor" shall mean the copyright owner or entity authorized by
593
+ > the copyright owner that is granting the License.
594
+ >
595
+ > "Legal Entity" shall mean the union of the acting entity and all
596
+ > other entities that control, are controlled by, or are under common
597
+ > control with that entity. For the purposes of this definition,
598
+ > "control" means (i) the power, direct or indirect, to cause the
599
+ > direction or management of such entity, whether by contract or
600
+ > otherwise, or (ii) ownership of fifty percent (50%) or more of the
601
+ > outstanding shares, or (iii) beneficial ownership of such entity.
602
+ >
603
+ > "You" (or "Your") shall mean an individual or Legal Entity
604
+ > exercising permissions granted by this License.
605
+ >
606
+ > "Source" form shall mean the preferred form for making modifications,
607
+ > including but not limited to software source code, documentation
608
+ > source, and configuration files.
609
+ >
610
+ > "Object" form shall mean any form resulting from mechanical
611
+ > transformation or translation of a Source form, including but
612
+ > not limited to compiled object code, generated documentation,
613
+ > and conversions to other media types.
614
+ >
615
+ > "Work" shall mean the work of authorship, whether in Source or
616
+ > Object form, made available under the License, as indicated by a
617
+ > copyright notice that is included in or attached to the work
618
+ > (an example is provided in the Appendix below).
619
+ >
620
+ > "Derivative Works" shall mean any work, whether in Source or Object
621
+ > form, that is based on (or derived from) the Work and for which the
622
+ > editorial revisions, annotations, elaborations, or other modifications
623
+ > represent, as a whole, an original work of authorship. For the purposes
624
+ > of this License, Derivative Works shall not include works that remain
625
+ > separable from, or merely link (or bind by name) to the interfaces of,
626
+ > the Work and Derivative Works thereof.
627
+ >
628
+ > "Contribution" shall mean any work of authorship, including
629
+ > the original version of the Work and any modifications or additions
630
+ > to that Work or Derivative Works thereof, that is intentionally
631
+ > submitted to Licensor for inclusion in the Work by the copyright owner
632
+ > or by an individual or Legal Entity authorized to submit on behalf of
633
+ > the copyright owner. For the purposes of this definition, "submitted"
634
+ > means any form of electronic, verbal, or written communication sent
635
+ > to the Licensor or its representatives, including but not limited to
636
+ > communication on electronic mailing lists, source code control systems,
637
+ > and issue tracking systems that are managed by, or on behalf of, the
638
+ > Licensor for the purpose of discussing and improving the Work, but
639
+ > excluding communication that is conspicuously marked or otherwise
640
+ > designated in writing by the copyright owner as "Not a Contribution."
641
+ >
642
+ > "Contributor" shall mean Licensor and any individual or Legal Entity
643
+ > on behalf of whom a Contribution has been received by Licensor and
644
+ > subsequently incorporated within the Work.
645
+ >
646
+ > 2. Grant of Copyright License. Subject to the terms and conditions of
647
+ > this License, each Contributor hereby grants to You a perpetual,
648
+ > worldwide, non-exclusive, no-charge, royalty-free, irrevocable
649
+ > copyright license to reproduce, prepare Derivative Works of,
650
+ > publicly display, publicly perform, sublicense, and distribute the
651
+ > Work and such Derivative Works in Source or Object form.
652
+ >
653
+ > 3. Grant of Patent License. Subject to the terms and conditions of
654
+ > this License, each Contributor hereby grants to You a perpetual,
655
+ > worldwide, non-exclusive, no-charge, royalty-free, irrevocable
656
+ > (except as stated in this section) patent license to make, have made,
657
+ > use, offer to sell, sell, import, and otherwise transfer the Work,
658
+ > where such license applies only to those patent claims licensable
659
+ > by such Contributor that are necessarily infringed by their
660
+ > Contribution(s) alone or by combination of their Contribution(s)
661
+ > with the Work to which such Contribution(s) was submitted. If You
662
+ > institute patent litigation against any entity (including a
663
+ > cross-claim or counterclaim in a lawsuit) alleging that the Work
664
+ > or a Contribution incorporated within the Work constitutes direct
665
+ > or contributory patent infringement, then any patent licenses
666
+ > granted to You under this License for that Work shall terminate
667
+ > as of the date such litigation is filed.
668
+ >
669
+ > 4. Redistribution. You may reproduce and distribute copies of the
670
+ > Work or Derivative Works thereof in any medium, with or without
671
+ > modifications, and in Source or Object form, provided that You
672
+ > meet the following conditions:
673
+ >
674
+ > (a) You must give any other recipients of the Work or
675
+ > Derivative Works a copy of this License; and
676
+ >
677
+ > (b) You must cause any modified files to carry prominent notices
678
+ > stating that You changed the files; and
679
+ >
680
+ > (c) You must retain, in the Source form of any Derivative Works
681
+ > that You distribute, all copyright, patent, trademark, and
682
+ > attribution notices from the Source form of the Work,
683
+ > excluding those notices that do not pertain to any part of
684
+ > the Derivative Works; and
685
+ >
686
+ > (d) If the Work includes a "NOTICE" text file as part of its
687
+ > distribution, then any Derivative Works that You distribute must
688
+ > include a readable copy of the attribution notices contained
689
+ > within such NOTICE file, excluding those notices that do not
690
+ > pertain to any part of the Derivative Works, in at least one
691
+ > of the following places: within a NOTICE text file distributed
692
+ > as part of the Derivative Works; within the Source form or
693
+ > documentation, if provided along with the Derivative Works; or,
694
+ > within a display generated by the Derivative Works, if and
695
+ > wherever such third-party notices normally appear. The contents
696
+ > of the NOTICE file are for informational purposes only and
697
+ > do not modify the License. You may add Your own attribution
698
+ > notices within Derivative Works that You distribute, alongside
699
+ > or as an addendum to the NOTICE text from the Work, provided
700
+ > that such additional attribution notices cannot be construed
701
+ > as modifying the License.
702
+ >
703
+ > You may add Your own copyright statement to Your modifications and
704
+ > may provide additional or different license terms and conditions
705
+ > for use, reproduction, or distribution of Your modifications, or
706
+ > for any such Derivative Works as a whole, provided Your use,
707
+ > reproduction, and distribution of the Work otherwise complies with
708
+ > the conditions stated in this License.
709
+ >
710
+ > 5. Submission of Contributions. Unless You explicitly state otherwise,
711
+ > any Contribution intentionally submitted for inclusion in the Work
712
+ > by You to the Licensor shall be under the terms and conditions of
713
+ > this License, without any additional terms or conditions.
714
+ > Notwithstanding the above, nothing herein shall supersede or modify
715
+ > the terms of any separate license agreement you may have executed
716
+ > with Licensor regarding such Contributions.
717
+ >
718
+ > 6. Trademarks. This License does not grant permission to use the trade
719
+ > names, trademarks, service marks, or product names of the Licensor,
720
+ > except as required for reasonable and customary use in describing the
721
+ > origin of the Work and reproducing the content of the NOTICE file.
722
+ >
723
+ > 7. Disclaimer of Warranty. Unless required by applicable law or
724
+ > agreed to in writing, Licensor provides the Work (and each
725
+ > Contributor provides its Contributions) on an "AS IS" BASIS,
726
+ > WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
727
+ > implied, including, without limitation, any warranties or conditions
728
+ > of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
729
+ > PARTICULAR PURPOSE. You are solely responsible for determining the
730
+ > appropriateness of using or redistributing the Work and assume any
731
+ > risks associated with Your exercise of permissions under this License.
732
+ >
733
+ > 8. Limitation of Liability. In no event and under no legal theory,
734
+ > whether in tort (including negligence), contract, or otherwise,
735
+ > unless required by applicable law (such as deliberate and grossly
736
+ > negligent acts) or agreed to in writing, shall any Contributor be
737
+ > liable to You for damages, including any direct, indirect, special,
738
+ > incidental, or consequential damages of any character arising as a
739
+ > result of this License or out of the use or inability to use the
740
+ > Work (including but not limited to damages for loss of goodwill,
741
+ > work stoppage, computer failure or malfunction, or any and all
742
+ > other commercial damages or losses), even if such Contributor
743
+ > has been advised of the possibility of such damages.
744
+ >
745
+ > 9. Accepting Warranty or Additional Liability. While redistributing
746
+ > the Work or Derivative Works thereof, You may choose to offer,
747
+ > and charge a fee for, acceptance of support, warranty, indemnity,
748
+ > or other liability obligations and/or rights consistent with this
749
+ > License. However, in accepting such obligations, You may act only
750
+ > on Your own behalf and on Your sole responsibility, not on behalf
751
+ > of any other Contributor, and only if You agree to indemnify,
752
+ > defend, and hold each Contributor harmless for any liability
753
+ > incurred by, or claims asserted against, such Contributor by reason
754
+ > of your accepting any such warranty or additional liability.
755
+ >
756
+ > END OF TERMS AND CONDITIONS
757
+ >
758
+ > APPENDIX: How to apply the Apache License to your work.
759
+ >
760
+ > To apply the Apache License to your work, attach the following
761
+ > boilerplate notice, with the fields enclosed by brackets "[]"
762
+ > replaced with your own identifying information. (Don't include
763
+ > the brackets!) The text should be enclosed in the appropriate
764
+ > comment syntax for the file format. We also recommend that a
765
+ > file or class name and description of purpose be included on the
766
+ > same "printed page" as the copyright notice for easier
767
+ > identification within third-party archives.
768
+ >
769
+ > Copyright [yyyy] [name of copyright owner]
770
+ >
771
+ > Licensed under the Apache License, Version 2.0 (the "License");
772
+ > you may not use this file except in compliance with the License.
773
+ > You may obtain a copy of the License at
774
+ >
775
+ > http://www.apache.org/licenses/LICENSE-2.0
776
+ >
777
+ > Unless required by applicable law or agreed to in writing, software
778
+ > distributed under the License is distributed on an "AS IS" BASIS,
779
+ > WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
780
+ > See the License for the specific language governing permissions and
781
+ > limitations under the License.
782
+
783
+ ---------------------------------------
784
+
578
785
  ## fast-glob
579
786
  License: MIT
580
787
  By: Denis Malinochkin
@@ -711,6 +918,35 @@ Repository: sindresorhus/get-stream
711
918
 
712
919
  ---------------------------------------
713
920
 
921
+ ## get-tsconfig
922
+ License: MIT
923
+ By: Hiroki Osame
924
+ Repository: privatenumber/get-tsconfig
925
+
926
+ > MIT License
927
+ >
928
+ > Copyright (c) Hiroki Osame <hiroki.osame@gmail.com>
929
+ >
930
+ > Permission is hereby granted, free of charge, to any person obtaining a copy
931
+ > of this software and associated documentation files (the "Software"), to deal
932
+ > in the Software without restriction, including without limitation the rights
933
+ > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
934
+ > copies of the Software, and to permit persons to whom the Software is
935
+ > furnished to do so, subject to the following conditions:
936
+ >
937
+ > The above copyright notice and this permission notice shall be included in all
938
+ > copies or substantial portions of the Software.
939
+ >
940
+ > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
941
+ > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
942
+ > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
943
+ > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
944
+ > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
945
+ > OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
946
+ > SOFTWARE.
947
+
948
+ ---------------------------------------
949
+
714
950
  ## glob-parent
715
951
  License: ISC
716
952
  By: Gulp Team, Elan Shanker, Blaine Bublitz
@@ -1258,7 +1494,7 @@ Repository: sindresorhus/mimic-fn
1258
1494
 
1259
1495
  > MIT License
1260
1496
  >
1261
- > Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (sindresorhus.com)
1497
+ > Copyright (c) Sindre Sorhus <sindresorhus@gmail.com> (https://sindresorhus.com)
1262
1498
  >
1263
1499
  > Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1264
1500
  >
@@ -1806,38 +2042,31 @@ Repository: chalk/slice-ansi
1806
2042
 
1807
2043
  ---------------------------------------
1808
2044
 
1809
- ## source-map-js
1810
- License: BSD-3-Clause
1811
- By: Valentin 7rulnik Semirulnik, Nick Fitzgerald, Tobias Koppers, Duncan Beevers, Stephen Crane, Ryan Seddon, Miles Elam, Mihai Bazon, Michael Ficarra, Todd Wolfson, Alexander Solovyov, Felix Gnass, Conrad Irwin, usrbincc, David Glasser, Chase Douglas, Evan Wallace, Heather Arthur, Hugh Kennedy, Simon Lydell, Jmeas Smith, Michael Z Goddard, azu, John Gozde, Adam Kirkton, Chris Montgomery, J. Ryan Stinnett, Jack Herrington, Chris Truter, Daniel Espeset, Jamie Wong, Eddy Bruël, Hawken Rives, Gilad Peleg, djchie, Gary Ye, Nicolas Lalevée
1812
- Repository: 7rulnik/source-map-js
2045
+ ## source-map-support
2046
+ License: MIT
2047
+ Repository: https://github.com/evanw/node-source-map-support
1813
2048
 
1814
- > Copyright (c) 2009-2011, Mozilla Foundation and contributors
1815
- > All rights reserved.
1816
- >
1817
- > Redistribution and use in source and binary forms, with or without
1818
- > modification, are permitted provided that the following conditions are met:
2049
+ > The MIT License (MIT)
1819
2050
  >
1820
- > * Redistributions of source code must retain the above copyright notice, this
1821
- > list of conditions and the following disclaimer.
2051
+ > Copyright (c) 2014 Evan Wallace
1822
2052
  >
1823
- > * Redistributions in binary form must reproduce the above copyright notice,
1824
- > this list of conditions and the following disclaimer in the documentation
1825
- > and/or other materials provided with the distribution.
2053
+ > Permission is hereby granted, free of charge, to any person obtaining a copy
2054
+ > of this software and associated documentation files (the "Software"), to deal
2055
+ > in the Software without restriction, including without limitation the rights
2056
+ > to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
2057
+ > copies of the Software, and to permit persons to whom the Software is
2058
+ > furnished to do so, subject to the following conditions:
1826
2059
  >
1827
- > * Neither the names of the Mozilla Foundation nor the names of project
1828
- > contributors may be used to endorse or promote products derived from this
1829
- > software without specific prior written permission.
2060
+ > The above copyright notice and this permission notice shall be included in all
2061
+ > copies or substantial portions of the Software.
1830
2062
  >
1831
- > THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
1832
- > ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
1833
- > WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
1834
- > DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
1835
- > FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1836
- > DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
1837
- > SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
1838
- > CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
1839
- > OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
1840
- > OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2063
+ > THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
2064
+ > IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
2065
+ > FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
2066
+ > AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
2067
+ > LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2068
+ > OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2069
+ > SOFTWARE.
1841
2070
 
1842
2071
  ---------------------------------------
1843
2072
 
package/dist/browser.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export { E as EnhancedSpy, r as Mock, u as MockContext, q as MockInstance, v as Mocked, w as MockedClass, o as MockedFunction, p as MockedObject, S as SpyInstance, j as afterAll, l as afterEach, h as beforeAll, k as beforeEach, n as createExpect, e as describe, m as expect, i as it, d as suite, t as test } from './index-220c1d70.js';
2
- import { R as ResolvedConfig } from './global-58e8e951.js';
3
- export { L as AfterSuiteRunMeta, A as ApiConfig, Y as ArgumentsType, X as Arrayable, P as Awaitable, ae as BaseCoverageOptions, ak as BenchFunction, ai as Benchmark, al as BenchmarkAPI, aj as BenchmarkResult, ah as BenchmarkUserOptions, B as BuiltinEnvironment, C as CSSModuleScopeStrategy, a0 as Constructable, ag as CoverageC8Options, af as CoverageIstanbulOptions, ac as CoverageOptions, a9 as CoverageProvider, aa as CoverageProviderModule, ab as CoverageReporter, _ as DeepMerge, D as DoneCallback, a3 as Environment, E as EnvironmentOptions, a2 as EnvironmentReturn, a7 as ErrorWithDiff, a as File, n as HookCleanupCallback, H as HookListener, I as InlineConfig, J as JSDOMOptions, Z as MergeInsertions, a1 as ModuleCache, M as ModuleGraphData, $ as MutableArray, Q as Nullable, a8 as OnServerRestartHandler, a6 as ParsedStack, a5 as Position, b as Reporter, K as ResolveIdFunction, R as ResolvedConfig, ad as ResolvedCoverageOptions, d as RunMode, r as RuntimeContext, u as SnapshotData, x as SnapshotMatchOptions, y as SnapshotResult, w as SnapshotStateOptions, G as SnapshotSummary, v as SnapshotUpdateState, S as Suite, m as SuiteAPI, p as SuiteCollector, q as SuiteFactory, o as SuiteHooks, i as Task, f as TaskBase, g as TaskResult, T as TaskResultPack, e as TaskState, h as Test, l as TestAPI, s as TestContext, j as TestFunction, k as TestOptions, z as UncheckedSnapshot, U as UserConfig, a4 as UserConsoleLog, t as Vitest, V as VitestEnvironment, c as VitestRunMode, W as WorkerContext, O as WorkerGlobalState, N as WorkerRPC } from './global-58e8e951.js';
1
+ export { A as AssertType, E as EnhancedSpy, q as ExpectTypeOf, x as Mock, y as MockContext, w as MockInstance, z as Mocked, B as MockedClass, u as MockedFunction, v as MockedObject, S as SpyInstance, j as afterAll, l as afterEach, r as assertType, h as beforeAll, k as beforeEach, n as createExpect, e as describe, m as expect, p as expectTypeOf, i as it, o as onTestFailed, d as suite, t as test } from './index-b68b3c09.js';
2
+ import { R as ResolvedConfig } from './types-b3ff5eea.js';
3
+ export { $ as AfterSuiteRunMeta, A as ApiConfig, a5 as ArgumentsType, a4 as Arrayable, a2 as Awaitable, an as BaseCoverageOptions, at as BenchFunction, ar as Benchmark, au as BenchmarkAPI, as as BenchmarkResult, aq as BenchmarkUserOptions, B as BuiltinEnvironment, h as CSSModuleScopeStrategy, C as CollectLineNumbers, e as CollectLines, a9 as Constructable, g as Context, ap as CoverageC8Options, ao as CoverageIstanbulOptions, al as CoverageOptions, ai as CoverageProvider, aj as CoverageProviderModule, ak as CoverageReporter, a7 as DeepMerge, D as DoneCallback, ac as Environment, E as EnvironmentOptions, ab as EnvironmentReturn, ag as ErrorWithDiff, a as File, v as HookCleanupCallback, H as HookListener, I as InlineConfig, J as JSDOMOptions, a6 as MergeInsertions, aa as ModuleCache, M as ModuleGraphData, a8 as MutableArray, a3 as Nullable, ah as OnServerRestartHandler, O as OnTestFailedHandler, af as ParsedStack, ae as Position, c as RawErrsMap, b as Reporter, _ as ResolveIdFunction, R as ResolvedConfig, am as ResolvedCoverageOptions, f as RootAndTarget, k as RunMode, z as RuntimeContext, L as SnapshotData, Q as SnapshotMatchOptions, W as SnapshotResult, P as SnapshotStateOptions, Y as SnapshotSummary, N as SnapshotUpdateState, S as Suite, u as SuiteAPI, x as SuiteCollector, y as SuiteFactory, w as SuiteHooks, q as Task, m as TaskBase, n as TaskResult, T as TaskResultPack, l as TaskState, o as Test, t as TestAPI, G as TestContext, r as TestFunction, s as TestOptions, d as TscErrorInfo, p as TypeCheck, j as TypecheckConfig, X as UncheckedSnapshot, U as UserConfig, ad as UserConsoleLog, K as Vitest, V as VitestEnvironment, i as VitestRunMode, Z as WorkerContext, a1 as WorkerGlobalState, a0 as WorkerRPC } from './types-b3ff5eea.js';
4
4
  import * as chai from 'chai';
5
5
  export { chai };
6
6
  export { assert, should } from 'chai';
package/dist/browser.js CHANGED
@@ -1,25 +1,32 @@
1
- export { c as createExpect, d as describe, e as expect, i as it, s as suite, t as test } from './chunk-runtime-chain.37ec5d73.js';
2
- export { a as afterAll, d as afterEach, b as beforeAll, c as beforeEach } from './chunk-runtime-hooks.d748b085.js';
3
- export { a as setupGlobalEnv, s as startTests } from './chunk-runtime-setup.ab6b6274.js';
1
+ export { c as createExpect, d as describe, e as expect, i as it, s as suite, t as test } from './chunk-runtime-chain.3b531731.js';
2
+ import { e as dist } from './chunk-runtime-test-state.31ce8643.js';
3
+ export { a as afterAll, d as afterEach, f as assertType, b as beforeAll, c as beforeEach, o as onTestFailed } from './chunk-runtime-test-state.31ce8643.js';
4
+ export { a as setupGlobalEnv, s as startTests } from './chunk-runtime-setup.f644ac4c.js';
4
5
  import * as chai from 'chai';
5
6
  export { chai };
6
7
  export { assert, should } from 'chai';
7
8
  import 'util';
8
- import './chunk-mock-date.030959d3.js';
9
+ import './chunk-typecheck-constants.410fa7b2.js';
9
10
  import 'path';
10
- import './chunk-utils-env.b1281522.js';
11
+ import './chunk-utils-env.7fe285cc.js';
11
12
  import 'tty';
12
13
  import 'url';
13
14
  import 'local-pkg';
14
15
  import './vendor-_commonjsHelpers.addc3445.js';
15
- import './chunk-runtime-rpc.b418c0ab.js';
16
- import './chunk-utils-timers.8fca243e.js';
16
+ import './chunk-runtime-rpc.4a2d45ab.js';
17
+ import './chunk-utils-timers.d1fcc6bb.js';
17
18
  import 'fs';
18
- import './chunk-utils-source-map.663e2952.js';
19
+ import './chunk-utils-source-map.1a66263d.js';
19
20
  import './spy.js';
20
21
  import 'tinyspy';
21
22
  import 'perf_hooks';
22
- import './chunk-integrations-coverage.cca09977.js';
23
- import './chunk-runtime-error.17751c39.js';
23
+ import './chunk-integrations-coverage.befed097.js';
24
+ import './chunk-runtime-error.3cc15c6f.js';
25
+ import 'source-map';
24
26
  import './chunk-env-node.700b7e95.js';
25
27
  import 'console';
28
+
29
+
30
+
31
+ var expectTypeOf = dist.expectTypeOf;
32
+ export { expectTypeOf };
@@ -1,5 +1,5 @@
1
1
  import { promises } from 'fs';
2
- import { c as createBirpc } from './chunk-vite-node-client.3868b3ba.js';
2
+ import { c as createBirpc } from './chunk-vite-node-client.13ea0a59.js';
3
3
  import require$$0$1 from 'stream';
4
4
  import require$$0 from 'zlib';
5
5
  import require$$3 from 'net';
@@ -9,18 +9,16 @@ import require$$2 from 'events';
9
9
  import require$$1 from 'https';
10
10
  import require$$2$1 from 'http';
11
11
  import url from 'url';
12
- import { A as API_PATH } from './chunk-utils-env.b1281522.js';
13
- import { i as interpretSourcePos, p as parseStacktrace } from './chunk-utils-source-map.663e2952.js';
12
+ import { A as API_PATH } from './chunk-utils-env.7fe285cc.js';
14
13
  import 'module';
15
14
  import 'vm';
16
- import './chunk-vite-node-utils.2144000e.js';
15
+ import './chunk-vite-node-utils.b89230f3.js';
16
+ import 'acorn';
17
17
  import 'path';
18
18
  import 'assert';
19
19
  import 'util';
20
20
  import 'debug';
21
21
  import 'tty';
22
- import './chunk-mock-date.030959d3.js';
23
- import 'local-pkg';
24
22
 
25
23
  /*! (c) 2020 Andrea Giammarchi */
26
24
 
@@ -2217,7 +2215,7 @@ const EventTarget = {
2217
2215
  * Register an event listener.
2218
2216
  *
2219
2217
  * @param {String} type A string representing the event type to listen for
2220
- * @param {Function} listener The listener to add
2218
+ * @param {(Function|Object)} handler The listener to add
2221
2219
  * @param {Object} [options] An options object specifies characteristics about
2222
2220
  * the event listener
2223
2221
  * @param {Boolean} [options.once=false] A `Boolean` indicating that the
@@ -2225,7 +2223,17 @@ const EventTarget = {
2225
2223
  * the listener would be automatically removed when invoked.
2226
2224
  * @public
2227
2225
  */
2228
- addEventListener(type, listener, options = {}) {
2226
+ addEventListener(type, handler, options = {}) {
2227
+ for (const listener of this.listeners(type)) {
2228
+ if (
2229
+ !options[kForOnEventAttribute$1] &&
2230
+ listener[kListener$1] === handler &&
2231
+ !listener[kForOnEventAttribute$1]
2232
+ ) {
2233
+ return;
2234
+ }
2235
+ }
2236
+
2229
2237
  let wrapper;
2230
2238
 
2231
2239
  if (type === 'message') {
@@ -2235,7 +2243,7 @@ const EventTarget = {
2235
2243
  });
2236
2244
 
2237
2245
  event[kTarget] = this;
2238
- listener.call(this, event);
2246
+ callListener(handler, this, event);
2239
2247
  };
2240
2248
  } else if (type === 'close') {
2241
2249
  wrapper = function onClose(code, message) {
@@ -2246,7 +2254,7 @@ const EventTarget = {
2246
2254
  });
2247
2255
 
2248
2256
  event[kTarget] = this;
2249
- listener.call(this, event);
2257
+ callListener(handler, this, event);
2250
2258
  };
2251
2259
  } else if (type === 'error') {
2252
2260
  wrapper = function onError(error) {
@@ -2256,21 +2264,21 @@ const EventTarget = {
2256
2264
  });
2257
2265
 
2258
2266
  event[kTarget] = this;
2259
- listener.call(this, event);
2267
+ callListener(handler, this, event);
2260
2268
  };
2261
2269
  } else if (type === 'open') {
2262
2270
  wrapper = function onOpen() {
2263
2271
  const event = new Event('open');
2264
2272
 
2265
2273
  event[kTarget] = this;
2266
- listener.call(this, event);
2274
+ callListener(handler, this, event);
2267
2275
  };
2268
2276
  } else {
2269
2277
  return;
2270
2278
  }
2271
2279
 
2272
2280
  wrapper[kForOnEventAttribute$1] = !!options[kForOnEventAttribute$1];
2273
- wrapper[kListener$1] = listener;
2281
+ wrapper[kListener$1] = handler;
2274
2282
 
2275
2283
  if (options.once) {
2276
2284
  this.once(type, wrapper);
@@ -2283,7 +2291,7 @@ const EventTarget = {
2283
2291
  * Remove an event listener.
2284
2292
  *
2285
2293
  * @param {String} type A string representing the event type to remove
2286
- * @param {Function} handler The listener to remove
2294
+ * @param {(Function|Object)} handler The listener to remove
2287
2295
  * @public
2288
2296
  */
2289
2297
  removeEventListener(type, handler) {
@@ -2304,6 +2312,22 @@ var eventTarget = {
2304
2312
  MessageEvent
2305
2313
  };
2306
2314
 
2315
+ /**
2316
+ * Call an event listener
2317
+ *
2318
+ * @param {(Function|Object)} listener The listener to call
2319
+ * @param {*} thisArg The value to use as `this`` when calling the listener
2320
+ * @param {Event} event The event to pass to the listener
2321
+ * @private
2322
+ */
2323
+ function callListener(listener, thisArg, event) {
2324
+ if (typeof listener === 'object' && listener.handleEvent) {
2325
+ listener.handleEvent.call(listener, event);
2326
+ } else {
2327
+ listener.call(thisArg, event);
2328
+ }
2329
+ }
2330
+
2307
2331
  const { tokenChars: tokenChars$1 } = validation.exports;
2308
2332
 
2309
2333
  /**
@@ -4532,11 +4556,6 @@ class WebSocketReporter {
4532
4556
  async onTaskUpdate(packs) {
4533
4557
  if (this.clients.size === 0)
4534
4558
  return;
4535
- await Promise.all(packs.map(async (i) => {
4536
- var _a;
4537
- if ((_a = i[1]) == null ? void 0 : _a.error)
4538
- await interpretSourcePos(parseStacktrace(i[1].error), this.ctx);
4539
- }));
4540
4559
  this.clients.forEach((client) => {
4541
4560
  var _a;
4542
4561
  (_a = client.onTaskUpdate) == null ? void 0 : _a.call(client, packs);
@@ -2,15 +2,14 @@ import fs$2 from 'fs';
2
2
  import path$2 from 'path';
3
3
  import util from 'util';
4
4
  import childProcess$1 from 'child_process';
5
- import { p as pathKey, m as mergeStream$1, g as getStream$1, c as crossSpawn$1 } from './vendor-index.12d51d29.js';
6
- import { o as onetime$1 } from './vendor-index.9c919048.js';
5
+ import { p as pathKey, s as signalExit, m as mergeStream$1, g as getStream$1, c as crossSpawn$1 } from './vendor-index.22806ffb.js';
6
+ import { o as onetime$1 } from './vendor-index.808a85a6.js';
7
7
  import require$$0 from 'os';
8
- import { s as signalExit } from './vendor-index.1a291e86.js';
9
8
  import './vendor-_commonjsHelpers.addc3445.js';
10
- import 'buffer';
11
- import 'stream';
12
9
  import 'assert';
13
10
  import 'events';
11
+ import 'buffer';
12
+ import 'stream';
14
13
 
15
14
  var findUp$1 = {exports: {}};
16
15