@rstest/core 0.8.0 → 0.8.2

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.
package/LICENSE.md CHANGED
@@ -536,206 +536,6 @@ Licensed under BSD-3-Clause license in the repository at git+https://github.com/
536
536
  >
537
537
  > THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
538
538
 
539
- ### @vercel/detect-agent
540
-
541
- Licensed under Apache-2.0 license in the repository at https://github.com/vercel/vercel.git.
542
-
543
- > Apache License
544
- > Version 2.0, January 2004
545
- > http://www.apache.org/licenses/
546
- >
547
- > TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
548
- >
549
- > 1. Definitions.
550
- >
551
- > "License" shall mean the terms and conditions for use, reproduction,
552
- > and distribution as defined by Sections 1 through 9 of this document.
553
- >
554
- > "Licensor" shall mean the copyright owner or entity authorized by
555
- > the copyright owner that is granting the License.
556
- >
557
- > "Legal Entity" shall mean the union of the acting entity and all
558
- > other entities that control, are controlled by, or are under common
559
- > control with that entity. For the purposes of this definition,
560
- > "control" means (i) the power, direct or indirect, to cause the
561
- > direction or management of such entity, whether by contract or
562
- > otherwise, or (ii) ownership of fifty percent (50%) or more of the
563
- > outstanding shares, or (iii) beneficial ownership of such entity.
564
- >
565
- > "You" (or "Your") shall mean an individual or Legal Entity
566
- > exercising permissions granted by this License.
567
- >
568
- > "Source" form shall mean the preferred form for making modifications,
569
- > including but not limited to software source code, documentation
570
- > source, and configuration files.
571
- >
572
- > "Object" form shall mean any form resulting from mechanical
573
- > transformation or translation of a Source form, including but
574
- > not limited to compiled object code, generated documentation,
575
- > and conversions to other media types.
576
- >
577
- > "Work" shall mean the work of authorship, whether in Source or
578
- > Object form, made available under the License, as indicated by a
579
- > copyright notice that is included in or attached to the work
580
- > (an example is provided in the Appendix below).
581
- >
582
- > "Derivative Works" shall mean any work, whether in Source or Object
583
- > form, that is based on (or derived from) the Work and for which the
584
- > editorial revisions, annotations, elaborations, or other modifications
585
- > represent, as a whole, an original work of authorship. For the purposes
586
- > of this License, Derivative Works shall not include works that remain
587
- > separable from, or merely link (or bind by name) to the interfaces of,
588
- > the Work and Derivative Works thereof.
589
- >
590
- > "Contribution" shall mean any work of authorship, including
591
- > the original version of the Work and any modifications or additions
592
- > to that Work or Derivative Works thereof, that is intentionally
593
- > submitted to Licensor for inclusion in the Work by the copyright owner
594
- > or by an individual or Legal Entity authorized to submit on behalf of
595
- > the copyright owner. For the purposes of this definition, "submitted"
596
- > means any form of electronic, verbal, or written communication sent
597
- > to the Licensor or its representatives, including but not limited to
598
- > communication on electronic mailing lists, source code control systems,
599
- > and issue tracking systems that are managed by, or on behalf of, the
600
- > Licensor for the purpose of discussing and improving the Work, but
601
- > excluding communication that is conspicuously marked or otherwise
602
- > designated in writing by the copyright owner as "Not a Contribution."
603
- >
604
- > "Contributor" shall mean Licensor and any individual or Legal Entity
605
- > on behalf of whom a Contribution has been received by Licensor and
606
- > subsequently incorporated within the Work.
607
- >
608
- > 2. Grant of Copyright License. Subject to the terms and conditions of
609
- > this License, each Contributor hereby grants to You a perpetual,
610
- > worldwide, non-exclusive, no-charge, royalty-free, irrevocable
611
- > copyright license to reproduce, prepare Derivative Works of,
612
- > publicly display, publicly perform, sublicense, and distribute the
613
- > Work and such Derivative Works in Source or Object form.
614
- > 3. Grant of Patent License. Subject to the terms and conditions of
615
- > this License, each Contributor hereby grants to You a perpetual,
616
- > worldwide, non-exclusive, no-charge, royalty-free, irrevocable
617
- > (except as stated in this section) patent license to make, have made,
618
- > use, offer to sell, sell, import, and otherwise transfer the Work,
619
- > where such license applies only to those patent claims licensable
620
- > by such Contributor that are necessarily infringed by their
621
- > Contribution(s) alone or by combination of their Contribution(s)
622
- > with the Work to which such Contribution(s) was submitted. If You
623
- > institute patent litigation against any entity (including a
624
- > cross-claim or counterclaim in a lawsuit) alleging that the Work
625
- > or a Contribution incorporated within the Work constitutes direct
626
- > or contributory patent infringement, then any patent licenses
627
- > granted to You under this License for that Work shall terminate
628
- > as of the date such litigation is filed.
629
- > 4. Redistribution. You may reproduce and distribute copies of the
630
- > Work or Derivative Works thereof in any medium, with or without
631
- > modifications, and in Source or Object form, provided that You
632
- > meet the following conditions:
633
- >
634
- > (a) You must give any other recipients of the Work or
635
- > Derivative Works a copy of this License; and
636
- >
637
- > (b) You must cause any modified files to carry prominent notices
638
- > stating that You changed the files; and
639
- >
640
- > (c) You must retain, in the Source form of any Derivative Works
641
- > that You distribute, all copyright, patent, trademark, and
642
- > attribution notices from the Source form of the Work,
643
- > excluding those notices that do not pertain to any part of
644
- > the Derivative Works; and
645
- >
646
- > (d) If the Work includes a "NOTICE" text file as part of its
647
- > distribution, then any Derivative Works that You distribute must
648
- > include a readable copy of the attribution notices contained
649
- > within such NOTICE file, excluding those notices that do not
650
- > pertain to any part of the Derivative Works, in at least one
651
- > of the following places: within a NOTICE text file distributed
652
- > as part of the Derivative Works; within the Source form or
653
- > documentation, if provided along with the Derivative Works; or,
654
- > within a display generated by the Derivative Works, if and
655
- > wherever such third-party notices normally appear. The contents
656
- > of the NOTICE file are for informational purposes only and
657
- > do not modify the License. You may add Your own attribution
658
- > notices within Derivative Works that You distribute, alongside
659
- > or as an addendum to the NOTICE text from the Work, provided
660
- > that such additional attribution notices cannot be construed
661
- > as modifying the License.
662
- >
663
- > You may add Your own copyright statement to Your modifications and
664
- > may provide additional or different license terms and conditions
665
- > for use, reproduction, or distribution of Your modifications, or
666
- > for any such Derivative Works as a whole, provided Your use,
667
- > reproduction, and distribution of the Work otherwise complies with
668
- > the conditions stated in this License.
669
- >
670
- > 5. Submission of Contributions. Unless You explicitly state otherwise,
671
- > any Contribution intentionally submitted for inclusion in the Work
672
- > by You to the Licensor shall be under the terms and conditions of
673
- > this License, without any additional terms or conditions.
674
- > Notwithstanding the above, nothing herein shall supersede or modify
675
- > the terms of any separate license agreement you may have executed
676
- > with Licensor regarding such Contributions.
677
- > 6. Trademarks. This License does not grant permission to use the trade
678
- > names, trademarks, service marks, or product names of the Licensor,
679
- > except as required for reasonable and customary use in describing the
680
- > origin of the Work and reproducing the content of the NOTICE file.
681
- > 7. Disclaimer of Warranty. Unless required by applicable law or
682
- > agreed to in writing, Licensor provides the Work (and each
683
- > Contributor provides its Contributions) on an "AS IS" BASIS,
684
- > WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
685
- > implied, including, without limitation, any warranties or conditions
686
- > of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
687
- > PARTICULAR PURPOSE. You are solely responsible for determining the
688
- > appropriateness of using or redistributing the Work and assume any
689
- > risks associated with Your exercise of permissions under this License.
690
- > 8. Limitation of Liability. In no event and under no legal theory,
691
- > whether in tort (including negligence), contract, or otherwise,
692
- > unless required by applicable law (such as deliberate and grossly
693
- > negligent acts) or agreed to in writing, shall any Contributor be
694
- > liable to You for damages, including any direct, indirect, special,
695
- > incidental, or consequential damages of any character arising as a
696
- > result of this License or out of the use or inability to use the
697
- > Work (including but not limited to damages for loss of goodwill,
698
- > work stoppage, computer failure or malfunction, or any and all
699
- > other commercial damages or losses), even if such Contributor
700
- > has been advised of the possibility of such damages.
701
- > 9. Accepting Warranty or Additional Liability. While redistributing
702
- > the Work or Derivative Works thereof, You may choose to offer,
703
- > and charge a fee for, acceptance of support, warranty, indemnity,
704
- > or other liability obligations and/or rights consistent with this
705
- > License. However, in accepting such obligations, You may act only
706
- > on Your own behalf and on Your sole responsibility, not on behalf
707
- > of any other Contributor, and only if You agree to indemnify,
708
- > defend, and hold each Contributor harmless for any liability
709
- > incurred by, or claims asserted against, such Contributor by reason
710
- > of your accepting any such warranty or additional liability.
711
- >
712
- > END OF TERMS AND CONDITIONS
713
- >
714
- > APPENDIX: How to apply the Apache License to your work.
715
- >
716
- > To apply the Apache License to your work, attach the following
717
- > boilerplate notice, with the fields enclosed by brackets "[]"
718
- > replaced with your own identifying information. (Don't include
719
- > the brackets!) The text should be enclosed in the appropriate
720
- > comment syntax for the file format. We also recommend that a
721
- > file or class name and description of purpose be included on the
722
- > same "printed page" as the copyright notice for easier
723
- > identification within third-party archives.
724
- >
725
- > Copyright 2017 Vercel, Inc.
726
- >
727
- > Licensed under the Apache License, Version 2.0 (the "License");
728
- > you may not use this file except in compliance with the License.
729
- > You may obtain a copy of the License at
730
- >
731
- > http://www.apache.org/licenses/LICENSE-2.0
732
- >
733
- > Unless required by applicable law or agreed to in writing, software
734
- > distributed under the License is distributed on an "AS IS" BASIS,
735
- > WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
736
- > See the License for the specific language governing permissions and
737
- > limitations under the License.
738
-
739
539
  ### @vitest/expect
740
540
 
741
541
  Licensed under MIT license in the repository at git+https://github.com/vitest-dev/vitest.git.
package/dist/0~130.js CHANGED
@@ -4,10 +4,8 @@ import { __webpack_require__ } from "./rslib-runtime.js";
4
4
  import { AssertionError, strict } from "node:assert";
5
5
  import { Console } from "node:console";
6
6
  import "./721.js";
7
- import { prettyTime } from "./2672.js";
7
+ import { prettyTime, color } from "./3160.js";
8
8
  const external_node_util_ = __webpack_require__("node:util");
9
- const picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
10
- var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
11
9
  const RealDate = Date;
12
10
  function createCustomConsole({ rpc, testPath, printConsoleTrace }) {
13
11
  const getConsoleTrace = ()=>{
@@ -26,13 +24,13 @@ function createCustomConsole({ rpc, testPath, printConsoleTrace }) {
26
24
  getPrettyName(type) {
27
25
  switch(type){
28
26
  case 'error':
29
- return picocolors_default().red(type);
27
+ return color.red(type);
30
28
  case 'warn':
31
- return picocolors_default().yellow(type);
29
+ return color.yellow(type);
32
30
  case 'info':
33
- return picocolors_default().cyan(type);
31
+ return color.cyan(type);
34
32
  default:
35
- return picocolors_default().gray(type);
33
+ return color.gray(type);
36
34
  }
37
35
  }
38
36
  _log(name, message, type = 'stdout') {
@@ -74,11 +72,11 @@ function createCustomConsole({ rpc, testPath, printConsoleTrace }) {
74
72
  }
75
73
  group(title, ...args) {
76
74
  this._groupDepth++;
77
- if (null != title || args.length > 0) this._log('group', picocolors_default().bold((0, external_node_util_.format)(title, ...args)));
75
+ if (null != title || args.length > 0) this._log('group', color.bold((0, external_node_util_.format)(title, ...args)));
78
76
  }
79
77
  groupCollapsed(title, ...args) {
80
78
  this._groupDepth++;
81
- if (null != title || args.length > 0) this._log('groupCollapsed', picocolors_default().bold((0, external_node_util_.format)(title, ...args)));
79
+ if (null != title || args.length > 0) this._log('groupCollapsed', color.bold((0, external_node_util_.format)(title, ...args)));
82
80
  }
83
81
  groupEnd() {
84
82
  if (this._groupDepth > 0) this._groupDepth--;
package/dist/0~1472.js CHANGED
@@ -1,15 +1,11 @@
1
1
  import 'module';
2
2
  /*#__PURE__*/ import.meta.url;
3
- import { __webpack_require__ } from "./rslib-runtime.js";
4
- import "./2672.js";
5
3
  import { createRequire } from "./4881.js";
6
4
  import { pathToFileURL } from "./6198.js";
7
5
  import "./1157.js";
8
- import { logger as logger_logger } from "./3278.js";
9
- const picocolors = __webpack_require__("../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js");
10
- var picocolors_default = /*#__PURE__*/ __webpack_require__.n(picocolors);
6
+ import { logger as logger_logger, color } from "./3160.js";
11
7
  async function loadBrowserModule(options = {}) {
12
- const coreVersion = "0.8.0";
8
+ const coreVersion = "0.8.2";
13
9
  const { projectRoots = [] } = options;
14
10
  let browserModule;
15
11
  let browserVersion;
@@ -29,9 +25,9 @@ async function loadBrowserModule(options = {}) {
29
25
  const browserPkg = userRequire(browserPkgPath);
30
26
  browserVersion = browserPkg.version;
31
27
  if (browserVersion !== coreVersion) {
32
- logger_logger.error(`\n${picocolors_default().red('Error:')} Version mismatch between ${picocolors_default().cyan('@rstest/core')} and ${picocolors_default().cyan('@rstest/browser')}.\n`);
33
- logger_logger.error(` @rstest/core version: ${picocolors_default().yellow(coreVersion)}\n @rstest/browser version: ${picocolors_default().yellow(browserVersion)}\n`);
34
- logger_logger.error(`Please ensure both packages have the same version:\n\n ${picocolors_default().cyan(`npm install @rstest/browser@${coreVersion}`)}\n`);
28
+ logger_logger.error(`\n${color.red('Error:')} Version mismatch between ${color.cyan('@rstest/core')} and ${color.cyan('@rstest/browser')}.\n`);
29
+ logger_logger.error(` @rstest/core version: ${color.yellow(coreVersion)}\n @rstest/browser version: ${color.yellow(browserVersion)}\n`);
30
+ logger_logger.error(`Please ensure both packages have the same version:\n\n ${color.cyan(`npm install @rstest/browser@${coreVersion}`)}\n`);
35
31
  process.exit(1);
36
32
  }
37
33
  return browserModule;
@@ -40,9 +36,9 @@ async function loadBrowserModule(options = {}) {
40
36
  if ('ERR_MODULE_NOT_FOUND' === err.code || 'MODULE_NOT_FOUND' === err.code) continue;
41
37
  throw error;
42
38
  }
43
- logger_logger.error(`\n${picocolors_default().red('Error:')} Browser mode requires ${picocolors_default().cyan('@rstest/browser')} to be installed.\n`);
44
- logger_logger.error(`Please install it with:\n\n ${picocolors_default().cyan(`npm install @rstest/browser@${coreVersion}`)}\n`);
45
- logger_logger.error(`Or if using pnpm:\n\n ${picocolors_default().cyan(`pnpm add @rstest/browser@${coreVersion}`)}\n`);
39
+ logger_logger.error(`\n${color.red('Error:')} Browser mode requires ${color.cyan('@rstest/browser')} to be installed.\n`);
40
+ logger_logger.error(`Please install it with:\n\n ${color.cyan(`npm install @rstest/browser@${coreVersion}`)}\n`);
41
+ logger_logger.error(`Or if using pnpm:\n\n ${color.cyan(`pnpm add @rstest/browser@${coreVersion}`)}\n`);
46
42
  process.exit(1);
47
43
  }
48
44
  export { loadBrowserModule };