Skip to content

Commit 573cd88

Browse files
committed
docs(readme): updated the readme
1 parent 3379c9e commit 573cd88

File tree

1 file changed

+78
-46
lines changed

1 file changed

+78
-46
lines changed

README.md

Lines changed: 78 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,54 @@
11
# Serenity/JS Playwright Component Test Template
22

33
[![Build Status](https://github.com/serenity-js/serenity-js-playwright-ct-react-template/actions/workflows/main.yml/badge.svg)](https://github.com/serenity-js/serenity-js-playwright-ct-react-template/actions/workflows/main.yml)
4-
[![Serenity/JS on GitHub](https://img.shields.io/badge/github-serenity--js-yellow?logo=github)](https://github.com/serenity-js/serenity-js)
5-
[![Serenity/JS on StackOverflow](https://img.shields.io/badge/stackoverflow-serenity--js-important?logo=stackoverflow)](https://stackoverflow.com/questions/tagged/serenity-js)
6-
[![Contribute with Gitpod](https://img.shields.io/badge/Contribute%20with-Gitpod-908a85?logo=gitpod)](https://gitpod.io/from-referrer/)
74

8-
[![Follow Serenity/JS on LinkedIn](https://img.shields.io/badge/Follow-Serenity%2FJS%20-0077B5?logo=linkedin)](https://www.linkedin.com/company/serenity-js)
9-
[![Watch Serenity/JS on YouTube](https://img.shields.io/badge/Watch-@serenity--js-E62117?logo=youtube)](https://www.youtube.com/@serenity-js)
10-
[![Join Serenity/JS Community Chat](https://img.shields.io/badge/Chat-Serenity%2FJS%20Community-FBD30B?logo=matrix)](https://matrix.to/#/#serenity-js:gitter.im)
11-
[![Support Serenity/JS on GitHub](https://img.shields.io/badge/Support-@serenity--js-703EC8?logo=github)](https://github.com/sponsors/serenity-js)
12-
13-
Use this [template repository](https://help.github.com/en/articles/creating-a-repository-from-a-template)
14-
to get started with testing your [React](https://react.dev/) components using [Serenity/JS](https://serenity-js.org),
15-
[Playwright](https://playwright.dev/) and [Playwright Component Test](https://playwright.dev/docs/test-components).
5+
This [template](https://help.github.com/en/articles/creating-a-repository-from-a-template) helps you test
6+
[React](https://react.dev/) components using [Serenity/JS](https://serenity-js.org) and the [Playwright Test](https://playwright.dev/) runner in [Component-Test mode](https://playwright.dev/docs/test-components), with a fully configured TypeScript setup.
167

17-
Learn more:
18-
- [Serenity BDD reports for this project](https://serenity-js.github.io/serenity-js-playwright-ct-react-template/serenity/)
19-
- [Playwright Test reports for this project](https://serenity-js.github.io/serenity-js-playwright-ct-react-template/playwright/)
20-
- [Serenity/JS website, tutorials, and API docs](https://serenity-js.org/)
8+
## Features
219

22-
## Usage
10+
- Preconfigured Serenity/JS + Playwright CT + TypeScript setup
11+
- Example React components and corresponding tests
12+
- Linting and CI-friendly scripts
13+
- Ready-to-use GitHub Codespaces environment using the official [Serenity/JS Docker image](https://serenity-js.org/handbook/integration/docker/) for quick exploration
14+
- Integrated reporting via Serenity BDD and Playwright, with live examples:
15+
- [Serenity BDD report](https://serenity-js.github.io/serenity-js-playwright-ct-react-template/serenity/)
16+
- [Playwright Test report](https://serenity-js.github.io/serenity-js-playwright-ct-react-template/playwright/)
2317

24-
This repository is a GitHub template. You can use it to [create a new GitHub repository](https://help.github.com/en/articles/creating-a-repository-from-a-template), [clone it to your computer](https://docs.github.com/en/free-pro-team@latest/github/creating-cloning-and-archiving-repositories/cloning-a-repository).
18+
## Quick Start
2519

26-
You can also launch it in a virtual Gitpod workspace without having to install anything on your machine:
20+
### Explore instantly in GitHub Codespaces
2721

28-
[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/from-referrer/)
22+
Launch this project in an online development environment:
2923

30-
### Installation
24+
[![Open in GitHub Codespaces](https://github.com/codespaces/badge.svg)](https://github.com/codespaces/new?ref=main&repo=serenity-js/serenity-js-playwright-ct-react-template)
3125

32-
To use this project on your machine, you'll need:
33-
- Node.js, a Long-Term Support (LTS) release version 16 or later - [download](https://nodejs.org/en/)
34-
- Java Runtime Environment (JRE) or a Java Development Kit (JDK) version 11 or later - [download](https://adoptopenjdk.net/)
26+
### Run locally
3527

36-
Follow the [installation instructions](https://serenity-js.org/handbook/about/installation/) to help you verify your setup.
37-
38-
Once you have the code on your computer, use your computer terminal to run the following command in the directory where you've cloned the project:
28+
- Follow the [Serenity/JS installation guide](https://serenity-js.org/handbook/about/installation/)
29+
- [Create a new repository](https://help.github.com/en/articles/creating-a-repository-from-a-template) from this template
30+
- [Clone](https://help.github.com/en/github/creating-cloning-and-archiving-repositories/cloning-a-repository) it to your machine
31+
- Install dependencies:
3932
```
4033
npm ci
4134
```
42-
43-
Running [`npm ci`](https://docs.npmjs.com/cli/v6/commands/npm-ci) downloads the [Node modules](https://docs.npmjs.com/about-packages-and-modules) this project depends on, as well as the [Serenity BDD CLI](https://github.com/serenity-bdd/serenity-cli) reporter jar.
35+
- Run the example tests
36+
```
37+
npm test
38+
```
39+
- View the generated reports:
40+
- **Serenity BDD**: `./target/site/serenity/index.html`
41+
- **Playwright Test**; `./playwright-report/index.html`
42+
- Serve the Serenity BDD report locally:
43+
```
44+
npm run start
45+
```
46+
Then open [http://localhost:8080](http://localhost:8080) in your browser.
4447

4548
### Corporate networks
4649

47-
If your network administrators require you to use proxy servers or an internal artifact registry (Artifactory, Nexus, etc.), your development environment might require some additional configuration.
48-
49-
The easiest way to do it is to create an [`.npmrc` file](https://docs.npmjs.com/cli/v6/configuring-npm/npmrc) in your home directory:
50+
If your environment requires proxy configuration or an internal registry like Artifactory or Nexus, add an [`.npmrc` file](https://docs.npmjs.com/cli/v6/configuring-npm/npmrc) file
51+
with the appropriate configuration to your home directory:
5052

5153
```
5254
proxy=http://user:[email protected]:8080/
@@ -55,9 +57,7 @@ strict-ssl=false
5557
registry=https://artifactory.mycompany.com/artifactory/
5658
```
5759

58-
If you encounter issues downloading the Serenity BDD CLI jar, please follow the [detailed instructions in the Serenity/JS Handbook](https://serenity-js.org/api/serenity-bdd/#downloading-the-serenity-bdd-reporting-cli).
59-
60-
### Execution
60+
## Execution
6161

6262
The project provides several [NPM scripts](https://docs.npmjs.com/cli/v6/using-npm/scripts) defined in [`package.json`](package.json):
6363

@@ -71,25 +71,57 @@ npm start # starts a mini HTTP server and serves the test reports
7171
# at http://localhost:8080
7272
```
7373

74-
## Your feedback matters!
74+
## Next steps
75+
76+
- Replace the sample components with your own UI elements
77+
- Add new tasks, interactions, and assertions using Serenity/JS
78+
- Extend the test suite or integrate it into CI/CD pipelines
79+
- Use the sample reports to understand expected testing and reporting workflows
7580

76-
Do you find Serenity/JS useful? Give it a ⭐ star on GitHub!
81+
## Documentation
7782

78-
[![GitHub stars](https://img.shields.io/github/stars/serenity-js/serenity-js)](https://github.com/serenity-js/serenity-js)
83+
- [API Reference](https://serenity-js.org/api/)
84+
- [Screenplay Pattern Guide](https://serenity-js.org/handbook/design/screenplay-pattern/)
85+
- [Serenity/JS Project Templates](https://serenity-js.org/handbook/project-templates/)
86+
- [More examples and reference implementations](https://github.com/serenity-js/serenity-js/tree/main/examples)
87+
- [Tutorial: First Web Scenario](https://serenity-js.org/handbook/tutorials/your-first-web-scenario/)
88+
- [Tutorial: First API Scenario](https://serenity-js.org/handbook/tutorials/your-first-api-scenario/)
7989

80-
Found a bug? Need a feature? Raise [an issue](https://github.com/serenity-js/serenity-js/issues?state=open)
81-
or submit a pull request.
90+
## Contributing
8291

83-
Have feedback? Let me know on [LinkedIn](https://www.linkedin.com/in/janmolak/) or leave a comment in [Serenity/JS discussions on GitHub](/serenity-js/serenity-js/discussions/categories/comments).
92+
Contributions of all kinds are welcome! Get started with the [Contributing Guide](https://serenity-js.org/community/contributing/).
8493

85-
And if you have any questions about the framework, or simply want to say hello to other Serenity/JS developers, join us on [Serenity/JS Community Chat](https://matrix.to/#/#serenity-js:gitter.im).
94+
## Community
8695

87-
## Support Serenity/JS
96+
Connect with other developers using Serenity/JS:
8897

89-
Serenity/JS is a free open-source framework, so we rely on our [wonderful GitHub sponsors](https://github.com/sponsors/serenity-js) to keep the lights on.
98+
- [Community Chat](https://matrix.to/#/#serenity-js:gitter.im)
99+
- [Discussions Forum](https://github.com/orgs/serenity-js/discussions)
100+
- Explore the [💡How to... ?](https://github.com/orgs/serenity-js/discussions/categories/how-to) answers to common questions
90101

91-
If you appreciate all the effort that goes into making sophisticated tools easy to work with, please support our work and [become a Serenity/JS GitHub Sponsor](https://github.com/sponsors/serenity-js) today!
102+
Follow Serenity/JS to learn about new features, tutorials, and releases!
103+
104+
[![Follow Serenity/JS on LinkedIn](https://img.shields.io/badge/LinkedIn-Serenity%2FJS%20-0077B5?logo=linkedin)](https://www.linkedin.com/company/serenity-js)
105+
[![Watch Serenity/JS on YouTube](https://img.shields.io/badge/Watch-@serenity--js-E62117?logo=youtube)](https://www.youtube.com/@serenity-js)
106+
[![Join Serenity/JS Community Chat](https://img.shields.io/badge/Chat-Serenity%2FJS%20Community-FBD30B?logo=matrix)](https://matrix.to/#/#serenity-js:gitter.im)
107+
108+
⭐ Star the main [Serenity/JS repository](https://github.com/serenity-js/serenity-js) to help others discover the framework!
109+
110+
[![GitHub stars](https://img.shields.io/github/stars/serenity-js/serenity-js?label=Serenity%2FJS&logo=github&style=badge)](https://github.com/serenity-js/serenity-js)
111+
112+
## License
113+
114+
The Serenity/JS code base is licensed under the [Apache-2.0](https://opensource.org/license/apache-2-0) license,
115+
while its documentation and the [Serenity/JS Handbook](https://serenity-js.org/handbook/) are licensed under the [Creative Commons BY-NC-SA 4.0 International](https://creativecommons.org/licenses/by-nc-sa/4.0/).
116+
117+
See the [Serenity/JS License](https://serenity-js.org/legal/license/).
118+
119+
## Support
120+
121+
Support ongoing development through [GitHub Sponsors](https://github.com/sponsors/serenity-js). Sponsors gain access to [Serenity/JS Playbooks](https://github.com/serenity-js/playbooks)
122+
and priority help in the [Discussions Forum](https://github.com/orgs/serenity-js/discussions).
123+
124+
For commercial support or corporate sponsorship, please contact [Jan Molak](https://www.linkedin.com/in/janmolak/).
92125

93-
[![LinkedIn Follow](https://img.shields.io/badge/Follow%20Serenity%2FJS-0077B5?style=for-the-badge&logo=linkedin&logoColor=white)](https://www.linkedin.com/company/serenity-js)
94-
[![YouTube Follow](https://img.shields.io/badge/Watch%20@serenity—JS-FA120F?style=for-the-badge&logo=youtube&logoColor=white)](https://www.youtube.com/@serenity-js)
95126
[![GitHub Sponsors](https://img.shields.io/badge/Support%20@serenity%2FJS-703EC8?style=for-the-badge&logo=github&logoColor=white)](https://github.com/sponsors/serenity-js)
127+

0 commit comments

Comments
 (0)