Initial commit: Crypto trader application

This commit is contained in:
2025-12-25 20:20:40 -05:00
commit 07a04c1bb8
47895 changed files with 2042266 additions and 0 deletions

202
frontend/node_modules/playwright/LICENSE generated vendored Normal file
View File

@@ -0,0 +1,202 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Portions Copyright (c) Microsoft Corporation.
Portions Copyright 2017 Google Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

5
frontend/node_modules/playwright/NOTICE generated vendored Normal file
View File

@@ -0,0 +1,5 @@
Playwright
Copyright (c) Microsoft Corporation
This software contains code derived from the Puppeteer project (https://github.com/puppeteer/puppeteer),
available under the Apache 2.0 license (https://github.com/puppeteer/puppeteer/blob/master/LICENSE).

168
frontend/node_modules/playwright/README.md generated vendored Normal file
View File

@@ -0,0 +1,168 @@
# 🎭 Playwright
[![npm version](https://img.shields.io/npm/v/playwright.svg)](https://www.npmjs.com/package/playwright) <!-- GEN:chromium-version-badge -->[![Chromium version](https://img.shields.io/badge/chromium-143.0.7499.4-blue.svg?logo=google-chrome)](https://www.chromium.org/Home)<!-- GEN:stop --> <!-- GEN:firefox-version-badge -->[![Firefox version](https://img.shields.io/badge/firefox-144.0.2-blue.svg?logo=firefoxbrowser)](https://www.mozilla.org/en-US/firefox/new/)<!-- GEN:stop --> <!-- GEN:webkit-version-badge -->[![WebKit version](https://img.shields.io/badge/webkit-26.0-blue.svg?logo=safari)](https://webkit.org/)<!-- GEN:stop --> [![Join Discord](https://img.shields.io/badge/join-discord-informational)](https://aka.ms/playwright/discord)
## [Documentation](https://playwright.dev) | [API reference](https://playwright.dev/docs/api/class-playwright)
Playwright is a framework for Web Testing and Automation. It allows testing [Chromium](https://www.chromium.org/Home), [Firefox](https://www.mozilla.org/en-US/firefox/new/) and [WebKit](https://webkit.org/) with a single API. Playwright is built to enable cross-browser web automation that is **ever-green**, **capable**, **reliable** and **fast**.
| | Linux | macOS | Windows |
| :--- | :---: | :---: | :---: |
| Chromium <!-- GEN:chromium-version -->143.0.7499.4<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |
| WebKit <!-- GEN:webkit-version -->26.0<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |
| Firefox <!-- GEN:firefox-version -->144.0.2<!-- GEN:stop --> | :white_check_mark: | :white_check_mark: | :white_check_mark: |
Headless execution is supported for all browsers on all platforms. Check out [system requirements](https://playwright.dev/docs/intro#system-requirements) for details.
Looking for Playwright for [Python](https://playwright.dev/python/docs/intro), [.NET](https://playwright.dev/dotnet/docs/intro), or [Java](https://playwright.dev/java/docs/intro)?
## Installation
Playwright has its own test runner for end-to-end tests, we call it Playwright Test.
### Using init command
The easiest way to get started with Playwright Test is to run the init command.
```Shell
# Run from your project's root directory
npm init playwright@latest
# Or create a new project
npm init playwright@latest new-project
```
This will create a configuration file, optionally add examples, a GitHub Action workflow and a first test example.spec.ts. You can now jump directly to writing assertions section.
### Manually
Add dependency and install browsers.
```Shell
npm i -D @playwright/test
# install supported browsers
npx playwright install
```
You can optionally install only selected browsers, see [install browsers](https://playwright.dev/docs/cli#install-browsers) for more details. Or you can install no browsers at all and use existing [browser channels](https://playwright.dev/docs/browsers).
* [Getting started](https://playwright.dev/docs/intro)
* [API reference](https://playwright.dev/docs/api/class-playwright)
## Capabilities
### Resilient • No flaky tests
**Auto-wait**. Playwright waits for elements to be actionable prior to performing actions. It also has a rich set of introspection events. The combination of the two eliminates the need for artificial timeouts - a primary cause of flaky tests.
**Web-first assertions**. Playwright assertions are created specifically for the dynamic web. Checks are automatically retried until the necessary conditions are met.
**Tracing**. Configure test retry strategy, capture execution trace, videos and screenshots to eliminate flakes.
### No trade-offs • No limits
Browsers run web content belonging to different origins in different processes. Playwright is aligned with the architecture of the modern browsers and runs tests out-of-process. This makes Playwright free of the typical in-process test runner limitations.
**Multiple everything**. Test scenarios that span multiple tabs, multiple origins and multiple users. Create scenarios with different contexts for different users and run them against your server, all in one test.
**Trusted events**. Hover elements, interact with dynamic controls and produce trusted events. Playwright uses real browser input pipeline indistinguishable from the real user.
Test frames, pierce Shadow DOM. Playwright selectors pierce shadow DOM and allow entering frames seamlessly.
### Full isolation • Fast execution
**Browser contexts**. Playwright creates a browser context for each test. Browser context is equivalent to a brand new browser profile. This delivers full test isolation with zero overhead. Creating a new browser context only takes a handful of milliseconds.
**Log in once**. Save the authentication state of the context and reuse it in all the tests. This bypasses repetitive log-in operations in each test, yet delivers full isolation of independent tests.
### Powerful Tooling
**[Codegen](https://playwright.dev/docs/codegen)**. Generate tests by recording your actions. Save them into any language.
**[Playwright inspector](https://playwright.dev/docs/inspector)**. Inspect page, generate selectors, step through the test execution, see click points and explore execution logs.
**[Trace Viewer](https://playwright.dev/docs/trace-viewer)**. Capture all the information to investigate the test failure. Playwright trace contains test execution screencast, live DOM snapshots, action explorer, test source and many more.
Looking for Playwright for [TypeScript](https://playwright.dev/docs/intro), [JavaScript](https://playwright.dev/docs/intro), [Python](https://playwright.dev/python/docs/intro), [.NET](https://playwright.dev/dotnet/docs/intro), or [Java](https://playwright.dev/java/docs/intro)?
## Examples
To learn how to run these Playwright Test examples, check out our [getting started docs](https://playwright.dev/docs/intro).
#### Page screenshot
This code snippet navigates to Playwright homepage and saves a screenshot.
```TypeScript
import { test } from '@playwright/test';
test('Page Screenshot', async ({ page }) => {
await page.goto('https://playwright.dev/');
await page.screenshot({ path: `example.png` });
});
```
#### Mobile and geolocation
This snippet emulates Mobile Safari on a device at given geolocation, navigates to maps.google.com, performs the action and takes a screenshot.
```TypeScript
import { test, devices } from '@playwright/test';
test.use({
...devices['iPhone 13 Pro'],
locale: 'en-US',
geolocation: { longitude: 12.492507, latitude: 41.889938 },
permissions: ['geolocation'],
})
test('Mobile and geolocation', async ({ page }) => {
await page.goto('https://maps.google.com');
await page.getByText('Your location').click();
await page.waitForRequest(/.*preview\/pwa/);
await page.screenshot({ path: 'colosseum-iphone.png' });
});
```
#### Evaluate in browser context
This code snippet navigates to example.com, and executes a script in the page context.
```TypeScript
import { test } from '@playwright/test';
test('Evaluate in browser context', async ({ page }) => {
await page.goto('https://www.example.com/');
const dimensions = await page.evaluate(() => {
return {
width: document.documentElement.clientWidth,
height: document.documentElement.clientHeight,
deviceScaleFactor: window.devicePixelRatio
}
});
console.log(dimensions);
});
```
#### Intercept network requests
This code snippet sets up request routing for a page to log all network requests.
```TypeScript
import { test } from '@playwright/test';
test('Intercept network requests', async ({ page }) => {
// Log and continue all network requests
await page.route('**', route => {
console.log(route.request().url());
route.continue();
});
await page.goto('http://todomvc.com');
});
```
## Resources
* [Documentation](https://playwright.dev)
* [API reference](https://playwright.dev/docs/api/class-playwright/)
* [Contribution guide](CONTRIBUTING.md)
* [Changelog](https://github.com/microsoft/playwright/releases)

6197
frontend/node_modules/playwright/ThirdPartyNotices.txt generated vendored Normal file

File diff suppressed because it is too large Load Diff

19
frontend/node_modules/playwright/cli.js generated vendored Executable file
View File

@@ -0,0 +1,19 @@
#!/usr/bin/env node
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
const { program } = require('./lib/program');
program.parse(process.argv);

17
frontend/node_modules/playwright/index.d.ts generated vendored Normal file
View File

@@ -0,0 +1,17 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export * from 'playwright-core';

17
frontend/node_modules/playwright/index.js generated vendored Normal file
View File

@@ -0,0 +1,17 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
module.exports = require('playwright-core');

18
frontend/node_modules/playwright/index.mjs generated vendored Normal file
View File

@@ -0,0 +1,18 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export * from 'playwright-core';
import playwright from 'playwright-core';
export default playwright;

42
frontend/node_modules/playwright/jsx-runtime.js generated vendored Normal file
View File

@@ -0,0 +1,42 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
function jsx(type, props, key) {
return {
__pw_type: 'jsx',
type,
props,
key,
};
}
function jsxs(type, props, key) {
return {
__pw_type: 'jsx',
type,
props,
key,
};
}
// this is used in <></> notation
const Fragment = { __pw_jsx_fragment: true };
module.exports = {
Fragment,
jsx,
jsxs,
};

21
frontend/node_modules/playwright/jsx-runtime.mjs generated vendored Normal file
View File

@@ -0,0 +1,21 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import jsxRuntime from './jsx-runtime.js';
export const jsx = jsxRuntime.jsx;
export const jsxs = jsxRuntime.jsxs;
export const Fragment = jsxRuntime.Fragment;

72
frontend/node_modules/playwright/package.json generated vendored Normal file
View File

@@ -0,0 +1,72 @@
{
"name": "playwright",
"version": "1.57.0",
"description": "A high-level API to automate web browsers",
"repository": {
"type": "git",
"url": "git+https://github.com/microsoft/playwright.git"
},
"homepage": "https://playwright.dev",
"engines": {
"node": ">=18"
},
"main": "index.js",
"exports": {
".": {
"types": "./index.d.ts",
"import": "./index.mjs",
"require": "./index.js",
"default": "./index.js"
},
"./package.json": "./package.json",
"./lib/common/configLoader": "./lib/common/configLoader.js",
"./lib/fsWatcher": "./lib/fsWatcher.js",
"./lib/mcp/index": "./lib/mcp/index.js",
"./lib/mcp/browser/tools": "./lib/mcp/browser/tools.js",
"./lib/mcp/program": "./lib/mcp/program.js",
"./lib/mcp/sdk/bundle": "./lib/mcp/sdk/bundle.js",
"./lib/mcp/sdk/exports": "./lib/mcp/sdk/exports.js",
"./lib/program": "./lib/program.js",
"./lib/reporters/base": "./lib/reporters/base.js",
"./lib/reporters/list": "./lib/reporters/list.js",
"./lib/transform/babelBundle": "./lib/transform/babelBundle.js",
"./lib/transform/compilationCache": "./lib/transform/compilationCache.js",
"./lib/transform/esmLoader": "./lib/transform/esmLoader.js",
"./lib/transform/transform": "./lib/transform/transform.js",
"./lib/internalsForTest": "./lib/internalsForTest.js",
"./lib/plugins": "./lib/plugins/index.js",
"./lib/runner/testRunner": "./lib/runner/testRunner.js",
"./jsx-runtime": {
"import": "./jsx-runtime.mjs",
"require": "./jsx-runtime.js",
"default": "./jsx-runtime.js"
},
"./lib/util": "./lib/util.js",
"./lib/utilsBundle": "./lib/utilsBundle.js",
"./types/test": {
"types": "./types/test.d.ts"
},
"./types/testReporter": {
"types": "./types/testReporter.d.ts"
},
"./test": {
"types": "./test.d.ts",
"import": "./test.mjs",
"require": "./test.js",
"default": "./test.js"
}
},
"bin": {
"playwright": "cli.js"
},
"author": {
"name": "Microsoft Corporation"
},
"license": "Apache-2.0",
"dependencies": {
"playwright-core": "1.57.0"
},
"optionalDependencies": {
"fsevents": "2.3.2"
}
}

18
frontend/node_modules/playwright/test.d.ts generated vendored Normal file
View File

@@ -0,0 +1,18 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
export * from './types/test';
export { default } from './types/test';

24
frontend/node_modules/playwright/test.js generated vendored Normal file
View File

@@ -0,0 +1,24 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
const pwt = require('./lib/index');
const playwright = require('./index');
const combinedExports = {
...playwright,
...pwt,
};
module.exports = Object.assign(combinedExports.test, combinedExports);

33
frontend/node_modules/playwright/test.mjs generated vendored Normal file
View File

@@ -0,0 +1,33 @@
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import playwright from './test.js';
export const chromium = playwright.chromium;
export const firefox = playwright.firefox;
export const webkit = playwright.webkit;
export const selectors = playwright.selectors;
export const devices = playwright.devices;
export const errors = playwright.errors;
export const request = playwright.request;
export const _electron = playwright._electron;
export const _android = playwright._android;
export const test = playwright.test;
export const expect = playwright.expect;
export const defineConfig = playwright.defineConfig;
export const mergeTests = playwright.mergeTests;
export const mergeExpects = playwright.mergeExpects;
export default playwright.test;

10253
frontend/node_modules/playwright/types/test.d.ts generated vendored Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,821 @@
// This file is generated by /utils/generate_types/index.js
/**
* Copyright (c) Microsoft Corporation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import type { TestStatus, Metadata, PlaywrightTestOptions, PlaywrightWorkerOptions, ReporterDescription, FullConfig, FullProject, Location } from './test';
export type { FullConfig, FullProject, TestStatus, Location } from './test';
/**
* Result of the full test run.
*/
export interface FullResult {
/**
* Status:
* - 'passed' - everything went as expected.
* - 'failed' - any test has failed.
* - 'timedout' - the global time has been reached.
* - 'interrupted' - interrupted by the user.
*/
status: 'passed' | 'failed' | 'timedout' | 'interrupted';
/**
* Test start wall time.
*/
startTime: Date;
/**
* Test duration in milliseconds.
*/
duration: number;
}
/**
* Test runner notifies the reporter about various events during test execution. All methods of the reporter are
* optional.
*
* You can create a custom reporter by implementing a class with some of the reporter methods. Make sure to export
* this class as default.
*
* ```js
* // my-awesome-reporter.ts
* import type {
* Reporter, FullConfig, Suite, TestCase, TestResult, FullResult
* } from '@playwright/test/reporter';
*
* class MyReporter implements Reporter {
* constructor(options: { customOption?: string } = {}) {
* console.log(`my-awesome-reporter setup with customOption set to ${options.customOption}`);
* }
*
* onBegin(config: FullConfig, suite: Suite) {
* console.log(`Starting the run with ${suite.allTests().length} tests`);
* }
*
* onTestBegin(test: TestCase) {
* console.log(`Starting test ${test.title}`);
* }
*
* onTestEnd(test: TestCase, result: TestResult) {
* console.log(`Finished test ${test.title}: ${result.status}`);
* }
*
* onEnd(result: FullResult) {
* console.log(`Finished the run: ${result.status}`);
* }
* }
* export default MyReporter;
* ```
*
* Now use this reporter with
* [testConfig.reporter](https://playwright.dev/docs/api/class-testconfig#test-config-reporter). Learn more about
* [using reporters](https://playwright.dev/docs/test-reporters).
*
* ```js
* // playwright.config.ts
* import { defineConfig } from '@playwright/test';
*
* export default defineConfig({
* reporter: [['./my-awesome-reporter.ts', { customOption: 'some value' }]],
* });
* ```
*
* Here is a typical order of reporter calls:
* - [reporter.onBegin(config, suite)](https://playwright.dev/docs/api/class-reporter#reporter-on-begin) is called
* once with a root suite that contains all other suites and tests. Learn more about
* [suites hierarchy][Suite](https://playwright.dev/docs/api/class-suite).
* - [reporter.onTestBegin(test, result)](https://playwright.dev/docs/api/class-reporter#reporter-on-test-begin) is
* called for each test run. It is given a [TestCase](https://playwright.dev/docs/api/class-testcase) that is
* executed, and a [TestResult](https://playwright.dev/docs/api/class-testresult) that is almost empty. Test
* result will be populated while the test runs (for example, with steps and stdio) and will get final `status`
* once the test finishes.
* - [reporter.onStepBegin(test, result, step)](https://playwright.dev/docs/api/class-reporter#reporter-on-step-begin)
* and
* [reporter.onStepEnd(test, result, step)](https://playwright.dev/docs/api/class-reporter#reporter-on-step-end)
* are called for each executed step inside the test. When steps are executed, test run has not finished yet.
* - [reporter.onTestEnd(test, result)](https://playwright.dev/docs/api/class-reporter#reporter-on-test-end) is
* called when test run has finished. By this time, [TestResult](https://playwright.dev/docs/api/class-testresult)
* is complete and you can use
* [testResult.status](https://playwright.dev/docs/api/class-testresult#test-result-status),
* [testResult.error](https://playwright.dev/docs/api/class-testresult#test-result-error) and more.
* - [reporter.onEnd(result)](https://playwright.dev/docs/api/class-reporter#reporter-on-end) is called once after
* all tests that should run had finished.
* - [reporter.onExit()](https://playwright.dev/docs/api/class-reporter#reporter-on-exit) is called immediately
* before the test runner exits.
*
* Additionally,
* [reporter.onStdOut(chunk, test, result)](https://playwright.dev/docs/api/class-reporter#reporter-on-std-out) and
* [reporter.onStdErr(chunk, test, result)](https://playwright.dev/docs/api/class-reporter#reporter-on-std-err) are
* called when standard output is produced in the worker process, possibly during a test execution, and
* [reporter.onError(error)](https://playwright.dev/docs/api/class-reporter#reporter-on-error) is called when
* something went wrong outside of the test execution.
*
* If your custom reporter does not print anything to the terminal, implement
* [reporter.printsToStdio()](https://playwright.dev/docs/api/class-reporter#reporter-prints-to-stdio) and return
* `false`. This way, Playwright will use one of the standard terminal reporters in addition to your custom reporter
* to enhance user experience.
*
* **Reporter errors**
*
* Playwright will swallow any errors thrown in your custom reporter methods. If you need to detect or fail on
* reporter errors, you must wrap and handle them yourself.
*
* **Merged report API notes**
*
* When merging multiple [`blob`](https://playwright.dev/docs/test-reporters#blob-reporter) reports via
* [`merge-reports`](https://playwright.dev/docs/test-sharding#merge-reports-cli) CLI command, the same
* [Reporter](https://playwright.dev/docs/api/class-reporter) API is called to produce final reports and all existing
* reporters should work without any changes. There some subtle differences though which might affect some custom
* reporters.
* - Projects from different shards are always kept as separate
* [TestProject](https://playwright.dev/docs/api/class-testproject) objects. E.g. if project 'Desktop Chrome' was
* sharded across 5 machines then there will be 5 instances of projects with the same name in the config passed to
* [reporter.onBegin(config, suite)](https://playwright.dev/docs/api/class-reporter#reporter-on-begin).
*/
export interface Reporter {
/**
* Called after all tests have been run, or testing has been interrupted. Note that this method may return a [Promise]
* and Playwright Test will await it. Reporter is allowed to override the status and hence affect the exit code of the
* test runner.
* @param result Result of the full test run, `status` can be one of:
* - `'passed'` - Everything went as expected.
* - `'failed'` - Any test has failed.
* - `'timedout'` - The
* [testConfig.globalTimeout](https://playwright.dev/docs/api/class-testconfig#test-config-global-timeout) has
* been reached.
* - `'interrupted'` - Interrupted by the user.
*/
onEnd?(result: FullResult): Promise<{ status?: FullResult['status'] } | undefined | void> | void;
/**
* Called once before running tests. All tests have been already discovered and put into a hierarchy of
* [Suite](https://playwright.dev/docs/api/class-suite)s.
* @param config Resolved configuration.
* @param suite The root suite that contains all projects, files and test cases.
*/
onBegin?(config: FullConfig, suite: Suite): void;
/**
* Called on some global error, for example unhandled exception in the worker process.
* @param error The error.
*/
onError?(error: TestError): void;
/**
* Called immediately before test runner exists. At this point all the reporters have received the
* [reporter.onEnd(result)](https://playwright.dev/docs/api/class-reporter#reporter-on-end) signal, so all the reports
* should be build. You can run the code that uploads the reports in this hook.
*/
onExit?(): Promise<void>;
/**
* Called when something has been written to the standard error in the worker process.
* @param chunk Output chunk.
* @param test Test that was running. Note that output may happen when no test is running, in which case this will be [void].
* @param result Result of the test run, this object gets populated while the test runs.
*/
onStdErr?(chunk: string|Buffer, test: void|TestCase, result: void|TestResult): void;
/**
* Called when something has been written to the standard output in the worker process.
* @param chunk Output chunk.
* @param test Test that was running. Note that output may happen when no test is running, in which case this will be [void].
* @param result Result of the test run, this object gets populated while the test runs.
*/
onStdOut?(chunk: string|Buffer, test: void|TestCase, result: void|TestResult): void;
/**
* Called when a test step started in the worker process.
* @param test Test that the step belongs to.
* @param result Result of the test run, this object gets populated while the test runs.
* @param step Test step instance that has started.
*/
onStepBegin?(test: TestCase, result: TestResult, step: TestStep): void;
/**
* Called when a test step finished in the worker process.
* @param test Test that the step belongs to.
* @param result Result of the test run.
* @param step Test step instance that has finished.
*/
onStepEnd?(test: TestCase, result: TestResult, step: TestStep): void;
/**
* Called after a test has been started in the worker process.
* @param test Test that has been started.
* @param result Result of the test run, this object gets populated while the test runs.
*/
onTestBegin?(test: TestCase, result: TestResult): void;
/**
* Called after a test has been finished in the worker process.
* @param test Test that has been finished.
* @param result Result of the test run.
*/
onTestEnd?(test: TestCase, result: TestResult): void;
/**
* Whether this reporter uses stdio for reporting. When it does not, Playwright Test could add some output to enhance
* user experience. If your reporter does not print to the terminal, it is strongly recommended to return `false`.
*/
printsToStdio?(): boolean;
}
export interface JSONReport {
config: Omit<FullConfig, 'projects'> & {
projects: {
outputDir: string,
repeatEach: number,
retries: number,
metadata: Metadata,
id: string,
name: string,
testDir: string,
testIgnore: string[],
testMatch: string[],
timeout: number,
}[],
};
suites: JSONReportSuite[];
errors: TestError[];
stats: {
startTime: string; // Date in ISO 8601 format.
duration: number; // In milliseconds;
expected: number;
unexpected: number;
flaky: number;
skipped: number;
}
}
export interface JSONReportSuite {
title: string;
file: string;
column: number;
line: number;
specs: JSONReportSpec[];
suites?: JSONReportSuite[];
}
export interface JSONReportSpec {
tags: string[],
title: string;
ok: boolean;
tests: JSONReportTest[];
id: string;
file: string;
line: number;
column: number;
}
export interface JSONReportTest {
timeout: number;
annotations: { type: string, description?: string }[],
expectedStatus: TestStatus;
projectName: string;
projectId: string;
results: JSONReportTestResult[];
status: 'skipped' | 'expected' | 'unexpected' | 'flaky';
}
export interface JSONReportError {
message: string;
location?: Location;
}
export interface JSONReportTestResult {
workerIndex: number;
parallelIndex: number;
status: TestStatus | undefined;
duration: number;
error: TestError | undefined;
errors: JSONReportError[];
stdout: JSONReportSTDIOEntry[];
stderr: JSONReportSTDIOEntry[];
retry: number;
steps?: JSONReportTestStep[];
startTime: string; // Date in ISO 8601 format.
attachments: {
name: string;
path?: string;
body?: string;
contentType: string;
}[];
annotations: { type: string, description?: string }[];
errorLocation?: Location;
}
export interface JSONReportTestStep {
title: string;
duration: number;
error: TestError | undefined;
steps?: JSONReportTestStep[];
}
export type JSONReportSTDIOEntry = { text: string } | { buffer: string };
// This is required to not export everything by default. See https://github.com/Microsoft/TypeScript/issues/19545#issuecomment-340490459
export {};
/**
* `Suite` is a group of tests. All tests in Playwright Test form the following hierarchy:
* - Root suite has a child suite for each [FullProject](https://playwright.dev/docs/api/class-fullproject).
* - Project suite #1. Has a child suite for each test file in the project.
* - File suite #1
* - [TestCase](https://playwright.dev/docs/api/class-testcase) #1
* - [TestCase](https://playwright.dev/docs/api/class-testcase) #2
* - Suite corresponding to a
* [test.describe([title, details, callback])](https://playwright.dev/docs/api/class-test#test-describe)
* group
* - [TestCase](https://playwright.dev/docs/api/class-testcase) #1 in a group
* - [TestCase](https://playwright.dev/docs/api/class-testcase) #2 in a group
* - < more test cases ... >
* - File suite #2
* - < more file suites ... >
* - Project suite #2
* - < more project suites ... >
*
* Reporter is given a root suite in the
* [reporter.onBegin(config, suite)](https://playwright.dev/docs/api/class-reporter#reporter-on-begin) method.
*/
export interface Suite {
/**
* Returns the list of all test cases in this suite and its descendants, as opposite to
* [suite.tests](https://playwright.dev/docs/api/class-suite#suite-tests).
*/
allTests(): Array<TestCase>;
/**
* Test cases and suites defined directly in this suite. The elements are returned in their declaration order. You can
* differentiate between various entry types by using
* [testCase.type](https://playwright.dev/docs/api/class-testcase#test-case-type) and
* [suite.type](https://playwright.dev/docs/api/class-suite#suite-type).
*/
entries(): Array<TestCase|Suite>;
/**
* Configuration of the project this suite belongs to, or [void] for the root suite.
*/
project(): FullProject|undefined;
/**
* Returns a list of titles from the root down to this suite.
*/
titlePath(): Array<string>;
/**
* Location in the source where the suite is defined. Missing for root and project suites.
*/
location?: Location;
/**
* Parent suite, missing for the root suite.
*/
parent?: Suite;
/**
* Child suites. See [Suite](https://playwright.dev/docs/api/class-suite) for the hierarchy of suites.
*/
suites: Array<Suite>;
/**
* Test cases in the suite. Note that only test cases defined directly in this suite are in the list. Any test cases
* defined in nested
* [test.describe([title, details, callback])](https://playwright.dev/docs/api/class-test#test-describe) groups are
* listed in the child [suite.suites](https://playwright.dev/docs/api/class-suite#suite-suites).
*/
tests: Array<TestCase>;
/**
* Suite title.
* - Empty for root suite.
* - Project name for project suite.
* - File path for file suite.
* - Title passed to
* [test.describe([title, details, callback])](https://playwright.dev/docs/api/class-test#test-describe) for a
* group suite.
*/
title: string;
/**
* Returns the type of the suite. The Suites form the following hierarchy: `root` -> `project` -> `file` -> `describe`
* -> ...`describe` -> `test`.
*/
type: "root"|"project"|"file"|"describe";
}
/**
* `TestCase` corresponds to every
* [test.(call)(title[, details, body])](https://playwright.dev/docs/api/class-test#test-call) call in a test file.
* When a single [test.(call)(title[, details, body])](https://playwright.dev/docs/api/class-test#test-call) is
* running in multiple projects or repeated multiple times, it will have multiple `TestCase` objects in corresponding
* projects' suites.
*/
export interface TestCase {
/**
* Whether the test is considered running fine. Non-ok tests fail the test run with non-zero exit code.
*/
ok(): boolean;
/**
* Testing outcome for this test. Note that outcome is not the same as
* [testResult.status](https://playwright.dev/docs/api/class-testresult#test-result-status):
* - Test that is expected to fail and actually fails is `'expected'`.
* - Test that passes on a second retry is `'flaky'`.
*/
outcome(): "skipped"|"expected"|"unexpected"|"flaky";
/**
* Returns a list of titles from the root down to this test.
*/
titlePath(): Array<string>;
/**
* [testResult.annotations](https://playwright.dev/docs/api/class-testresult#test-result-annotations) of the last test
* run.
*/
annotations: Array<{
/**
* Annotation type, for example `'skip'` or `'fail'`.
*/
type: string;
/**
* Optional description.
*/
description?: string;
/**
* Optional location in the source where the annotation is added.
*/
location?: Location;
}>;
/**
* Expected test status.
* - Tests marked as
* [test.skip([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-skip)
* or
* [test.fixme([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-fixme)
* are expected to be `'skipped'`.
* - Tests marked as
* [test.fail([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-fail)
* are expected to be `'failed'`.
* - Other tests are expected to be `'passed'`.
*
* See also [testResult.status](https://playwright.dev/docs/api/class-testresult#test-result-status) for the actual
* status.
*/
expectedStatus: "passed"|"failed"|"timedOut"|"skipped"|"interrupted";
/**
* A test ID that is computed based on the test file name, test title and project name. The ID is unique within
* Playwright session.
*/
id: string;
/**
* Location in the source where the test is defined.
*/
location: Location;
/**
* Suite this test case belongs to.
*/
parent: Suite;
/**
* Contains the repeat index when running in "repeat each" mode. This mode is enabled by passing `--repeat-each` to
* the [command line](https://playwright.dev/docs/test-cli).
*/
repeatEachIndex: number;
/**
* Results for each run of this test.
*/
results: Array<TestResult>;
/**
* The maximum number of retries given to this test in the configuration.
*
* Learn more about [test retries](https://playwright.dev/docs/test-retries#retries).
*/
retries: number;
/**
* The list of tags defined on the test or suite via
* [test.(call)(title[, details, body])](https://playwright.dev/docs/api/class-test#test-call) or
* [test.describe([title, details, callback])](https://playwright.dev/docs/api/class-test#test-describe), as well as
* `@`-tokens extracted from test and suite titles.
*
* Learn more about [test tags](https://playwright.dev/docs/test-annotations#tag-tests).
*/
tags: Array<string>;
/**
* The timeout given to the test. Affected by
* [testConfig.timeout](https://playwright.dev/docs/api/class-testconfig#test-config-timeout),
* [testProject.timeout](https://playwright.dev/docs/api/class-testproject#test-project-timeout),
* [test.setTimeout(timeout)](https://playwright.dev/docs/api/class-test#test-set-timeout),
* [test.slow([condition, callback, description])](https://playwright.dev/docs/api/class-test#test-slow) and
* [testInfo.setTimeout(timeout)](https://playwright.dev/docs/api/class-testinfo#test-info-set-timeout).
*/
timeout: number;
/**
* Test title as passed to the
* [test.(call)(title[, details, body])](https://playwright.dev/docs/api/class-test#test-call) call.
*/
title: string;
/**
* Returns "test". Useful for detecting test cases in
* [suite.entries()](https://playwright.dev/docs/api/class-suite#suite-entries).
*/
type: "test";
}
/**
* Information about an error thrown during test execution.
*/
export interface TestError {
/**
* Error cause. Set when there is a
* [cause](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/cause) for the
* error. Will be `undefined` if there is no cause or if the cause is not an instance of [Error].
*/
cause?: TestError;
/**
* Error location in the source code.
*/
location?: Location;
/**
* Error message. Set when [Error] (or its subclass) has been thrown.
*/
message?: string;
/**
* Source code snippet with highlighted error.
*/
snippet?: string;
/**
* Error stack. Set when [Error] (or its subclass) has been thrown.
*/
stack?: string;
/**
* The value that was thrown. Set when anything except the [Error] (or its subclass) has been thrown.
*/
value?: string;
}
/**
* A result of a single [TestCase](https://playwright.dev/docs/api/class-testcase) run.
*/
export interface TestResult {
/**
* The list of annotations applicable to the current test. Includes:
* - annotations defined on the test or suite via
* [test.(call)(title[, details, body])](https://playwright.dev/docs/api/class-test#test-call) and
* [test.describe([title, details, callback])](https://playwright.dev/docs/api/class-test#test-describe);
* - annotations implicitly added by methods
* [test.skip([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-skip),
* [test.fixme([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-fixme)
* and
* [test.fail([title, details, body, condition, callback, description])](https://playwright.dev/docs/api/class-test#test-fail);
* - annotations appended to
* [testInfo.annotations](https://playwright.dev/docs/api/class-testinfo#test-info-annotations) during the test
* execution.
*
* Annotations are available during test execution through
* [testInfo.annotations](https://playwright.dev/docs/api/class-testinfo#test-info-annotations).
*
* Learn more about [test annotations](https://playwright.dev/docs/test-annotations).
*/
annotations: Array<{
/**
* Annotation type, for example `'skip'` or `'fail'`.
*/
type: string;
/**
* Optional description.
*/
description?: string;
/**
* Optional location in the source where the annotation is added.
*/
location?: Location;
}>;
/**
* The list of files or buffers attached during the test execution through
* [testInfo.attachments](https://playwright.dev/docs/api/class-testinfo#test-info-attachments).
*/
attachments: Array<{
/**
* Attachment name.
*/
name: string;
/**
* Content type of this attachment to properly present in the report, for example `'application/json'` or
* `'image/png'`.
*/
contentType: string;
/**
* Optional path on the filesystem to the attached file.
*/
path?: string;
/**
* Optional attachment body used instead of a file.
*/
body?: Buffer;
}>;
/**
* Running time in milliseconds.
*/
duration: number;
/**
* First error thrown during test execution, if any. This is equal to the first element in
* [testResult.errors](https://playwright.dev/docs/api/class-testresult#test-result-errors).
*/
error?: TestError;
/**
* Errors thrown during the test execution.
*/
errors: Array<TestError>;
/**
* The index of the worker between `0` and `workers - 1`. It is guaranteed that workers running at the same time have
* a different `parallelIndex`.
*/
parallelIndex: number;
/**
* When test is retried multiple times, each retry attempt is given a sequential number.
*
* Learn more about [test retries](https://playwright.dev/docs/test-retries#retries).
*/
retry: number;
/**
* Start time of this particular test run.
*/
startTime: Date;
/**
* The status of this test result. See also
* [testCase.expectedStatus](https://playwright.dev/docs/api/class-testcase#test-case-expected-status).
*/
status: "passed"|"failed"|"timedOut"|"skipped"|"interrupted";
/**
* Anything written to the standard error during the test run.
*/
stderr: Array<string|Buffer>;
/**
* Anything written to the standard output during the test run.
*/
stdout: Array<string|Buffer>;
/**
* List of steps inside this test run.
*/
steps: Array<TestStep>;
/**
* Index of the worker where the test was run. If the test was not run a single time, for example when the user
* interrupted testing, the only result will have a `workerIndex` equal to `-1`.
*
* Learn more about [parallelism and sharding](https://playwright.dev/docs/test-parallel) with Playwright Test.
*/
workerIndex: number;
}
/**
* Represents a step in the [TestRun].
*/
export interface TestStep {
/**
* Returns a list of step titles from the root step down to this step.
*/
titlePath(): Array<string>;
/**
* The list of annotations applicable to the current test step.
*/
annotations: Array<{
/**
* Annotation type, for example `'skip'`.
*/
type: string;
/**
* Optional description.
*/
description?: string;
/**
* Optional location in the source where the annotation is added.
*/
location?: Location;
}>;
/**
* The list of files or buffers attached in the step execution through
* [testInfo.attach(name[, options])](https://playwright.dev/docs/api/class-testinfo#test-info-attach).
*/
attachments: Array<{
/**
* Attachment name.
*/
name: string;
/**
* Content type of this attachment to properly present in the report, for example `'application/json'` or
* `'image/png'`.
*/
contentType: string;
/**
* Optional path on the filesystem to the attached file.
*/
path?: string;
/**
* Optional attachment body used instead of a file.
*/
body?: Buffer;
}>;
/**
* Step category to differentiate steps with different origin and verbosity. Built-in categories are:
* - `expect` for expect calls
* - `fixture` for fixtures setup and teardown
* - `hook` for hooks initialization and teardown
* - `pw:api` for Playwright API calls.
* - `test.step` for test.step API calls.
* - `test.attach` for testInfo.attach API calls.
*/
category: string;
/**
* Running time in milliseconds.
*/
duration: number;
/**
* Error thrown during the step execution, if any.
*/
error?: TestError;
/**
* Optional location in the source where the step is defined.
*/
location?: Location;
/**
* Parent step, if any.
*/
parent?: TestStep;
/**
* Start time of this particular test step.
*/
startTime: Date;
/**
* List of steps inside this step.
*/
steps: Array<TestStep>;
/**
* User-friendly test step title.
*/
title: string;
}