Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Format markdown files with Prettier #4853

Merged
merged 8 commits into from
Nov 10, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,23 @@ THIS IS NOT A HELP FORUM.
If you are experiencing problems with setting up Jest, please make sure to visit our Help page:
https://facebook.github.io/jest/help.html
-->

<!--
Before creating an issue please check the following:
* you are using the latest version of Jest
* try re-installing your node_modules folder
* run Jest once with `--no-cache` to see if that fixes the problem you are experiencing.
-->

**Do you want to request a *feature* or report a *bug*?**
**Do you want to request a _feature_ or report a _bug_?**

**What is the current behavior?**

**If the current behavior is a bug, please provide the steps to reproduce and either a repl.it demo through https://repl.it/languages/jest or a minimal repository on GitHub that we can `yarn install` and `yarn test`.**
**If the current behavior is a bug, please provide the steps to reproduce and
either a repl.it demo through https://repl.it/languages/jest or a minimal
repository on GitHub that we can `yarn install` and `yarn test`.**

**What is the expected behavior?**

**Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.**
**Please provide your exact Jest configuration and mention your Jest, node,
yarn/npm version and operating system.**
1 change: 1 addition & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. -->

<!-- Please remember to update CHANGELOG.md in the root of the project if you have not done so. -->

**Summary**
Expand Down
7 changes: 1 addition & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,5 @@
"flow.useNPMPackagedFlow": true,
"javascript.validate.enable": false,
"jest.pathToJest": "yarn jest --",
"prettier.eslintIntegration": true,
"prettier.parser": "flow",
"prettier.printWidth": 80,
"prettier.semi": true,
"prettier.singleQuote": true,
"prettier.trailingComma": "all"
"prettier.eslintIntegration": true
}
1,110 changes: 733 additions & 377 deletions CHANGELOG.md

Large diffs are not rendered by default.

115 changes: 74 additions & 41 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,56 +1,73 @@
# Contributing to Jest

Jest is one of Facebook's open source projects that is both under very active development and is also being used to ship code to everybody on [facebook.com](https://www.facebook.com). We're still working out the kinks to make contributing to this project as easy and transparent as possible, but we're not quite there yet. Hopefully this document makes the process for contributing clear and answers some questions that you may have.
Jest is one of Facebook's open source projects that is both under very active
development and is also being used to ship code to everybody on
[facebook.com](https://www.facebook.com). We're still working out the kinks to
make contributing to this project as easy and transparent as possible, but we're
not quite there yet. Hopefully this document makes the process for contributing
clear and answers some questions that you may have.

## [Code of Conduct](https://code.facebook.com/codeofconduct)

Facebook has adopted a Code of Conduct that we expect project participants to adhere to. Please read [the full text](https://code.facebook.com/codeofconduct) so that you can understand what actions will and will not be tolerated.
Facebook has adopted a Code of Conduct that we expect project participants to
adhere to. Please read [the full text](https://code.facebook.com/codeofconduct)
so that you can understand what actions will and will not be tolerated.

## Our Development Process

The core team works directly on GitHub and all work is public.

### `master` is unsafe

We will do our best to keep `master` in good shape, with tests passing at all times. But in order to move fast, we will make API changes that your application might not be compatible with. We will do our best to communicate these changes and always version appropriately so you can lock into a specific version if need be.
We will do our best to keep `master` in good shape, with tests passing at all
times. But in order to move fast, we will make API changes that your application
might not be compatible with. We will do our best to communicate these changes
and always version appropriately so you can lock into a specific version if need
be.

### Workflow and Pull Requests

The core team will be monitoring for pull requests. When we get one, we'll run some Facebook-specific integration tests on it first. From here, we'll need to get another person to sign off on the changes and then merge the pull request. For API changes we may need to fix internal uses, which could cause some delay. We'll do our best to provide updates and feedback throughout the process.
The core team will be monitoring for pull requests. When we get one, we'll run
some Facebook-specific integration tests on it first. From here, we'll need to
get another person to sign off on the changes and then merge the pull request.
For API changes we may need to fix internal uses, which could cause some delay.
We'll do our best to provide updates and feedback throughout the process.

*Before* submitting a pull request, please make sure the following is done…
_Before_ submitting a pull request, please make sure the following is done…

1. Fork the repo and create your branch from `master`.
A guide on how to fork a repository: https://help.github.com/articles/fork-a-repo/
1. Fork the repo and create your branch from `master`. A guide on how to fork a
repository: https://help.github.com/articles/fork-a-repo/

Open terminal (e.g. Terminal, iTerm, Git Bash or Git Shell) and type:

```sh
git clone https://github.com/<your_username>/jest
cd jest
git checkout -b my_branch
```
Note:
Replace `<your_username>` with your GitHub username

2. Jest uses [Yarn](https://code.facebook.com/posts/1840075619545360)
for running development scripts. If you haven't already done so,
please [install yarn](https://yarnpkg.com/en/docs/install).
Note: Replace `<your_username>` with your GitHub username

2. Jest uses [Yarn](https://code.facebook.com/posts/1840075619545360) for
running development scripts. If you haven't already done so, please
[install yarn](https://yarnpkg.com/en/docs/install).

3. Run `yarn install`. On Windows: To install
[Yarn](https://yarnpkg.com/en/docs/install#windows-tab) on Windows you may
need to download either node.js or Chocolatey<br />

```sh
yarn install
```

3. Run `yarn install`.
On Windows:
To install [Yarn](https://yarnpkg.com/en/docs/install#windows-tab) on Windows you may need to download either node.js or Chocolatey<br />
To check your version of Yarn and ensure it's installed you can type:

```sh
yarn install
```
To check your version of Yarn and ensure it's installed you can type:
```sh
yarn --version
```
```sh
yarn --version
```

4. If you've added code that should be tested, add tests. You
can use watch mode that continuously transforms changed files
to make your life easier.
4. If you've added code that should be tested, add tests. You can use watch mode
that continuously transforms changed files to make your life easier.

```sh
# in the background
Expand All @@ -59,9 +76,9 @@ The core team will be monitoring for pull requests. When we get one, we'll run s

5. If you've changed APIs, update the documentation.

6. Ensure the test suite passes via `yarn test`. To run the test suite you
may need to install Mercurial (`hg`). On macOS, this can be done
using [homebrew](http://brew.sh/): `brew install hg`.
6. Ensure the test suite passes via `yarn test`. To run the test suite you may
need to install Mercurial (`hg`). On macOS, this can be done using
[homebrew](http://brew.sh/): `brew install hg`.

```sh
brew install hg # maybe
Expand All @@ -72,12 +89,13 @@ The core team will be monitoring for pull requests. When we get one, we'll run s

#### Additional Workflow for any changes made to website or docs

If you are making changes to the website or documentation, test the website folder
and run the server to check if your changes are being displayed accurately.
If you are making changes to the website or documentation, test the website
folder and run the server to check if your changes are being displayed
accurately.

1. Locate to the website directory and install any website specific dependencies
by typing in `yarn`. Following steps are to be followed
for this purpose from the root directory.
by typing in `yarn`. Following steps are to be followed for this purpose from
the root directory.
```sh
cd website # Only needed if you are not already in the website directory
yarn
Expand All @@ -88,13 +106,18 @@ and run the server to check if your changes are being displayed accurately.

### Contributor License Agreement (CLA)

In order to accept your pull request, we need you to submit a CLA. You only need to do this once, so if you've done this for another Facebook open source project, you're good to go. If you are submitting a pull request for the first time, just let us know that you have completed the CLA and we can cross-check with your GitHub username.
In order to accept your pull request, we need you to submit a CLA. You only need
to do this once, so if you've done this for another Facebook open source
project, you're good to go. If you are submitting a pull request for the first
time, just let us know that you have completed the CLA and we can cross-check
with your GitHub username.

[Complete your CLA here.](https://code.facebook.com/cla)

## How to try a development build of Jest in another project

To link `jest` on the command line to `jest-cli/bin/jest.js` in a development build:
To link `jest` on the command line to `jest-cli/bin/jest.js` in a development
build:

```sh
cd /path/to/your/Jest_clone/packages/jest-cli
Expand Down Expand Up @@ -122,9 +145,11 @@ cd /path/to/another/project
jest [options] # run jest-cli/bin/jest.js in the development build
```

* To decide whether to specify any options, see `test` under `scripts` in the `package.json` file of the other project.
* To decide whether to specify any options, see `test` under `scripts` in the
`package.json` file of the other project.

To unlink `jest` on the command line from `jest-cli/bin/jest.js` in a development build:
To unlink `jest` on the command line from `jest-cli/bin/jest.js` in a
development build:

```sh
yarn unlink jest-cli
Expand All @@ -134,19 +159,26 @@ yarn unlink jest-cli

### Where to Find Known Issues

We will be using GitHub Issues for our public bugs. We will keep a close eye on this and try to make it clear when we have an internal fix in progress. Before filing a new issue, try to make sure your problem doesn't already exist.
We will be using GitHub Issues for our public bugs. We will keep a close eye on
this and try to make it clear when we have an internal fix in progress. Before
filing a new issue, try to make sure your problem doesn't already exist.

### Reporting New Issues

The best way to get your bug fixed is to provide a reduced test case. Please provide a public repository with a runnable example.
The best way to get your bug fixed is to provide a reduced test case. Please
provide a public repository with a runnable example.

### Security Bugs

Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe disclosure of security bugs. With that in mind, please do not file public issues; go through the process outlined on that page.
Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe
disclosure of security bugs. With that in mind, please do not file public
issues; go through the process outlined on that page.

## How to Get in Touch

* Discord - [#jest](https://discordapp.com/channels/102860784329052160/103622435865104384) on [Reactiflux](http://www.reactiflux.com/)
* Discord -
[#jest](https://discordapp.com/channels/102860784329052160/103622435865104384)
on [Reactiflux](http://www.reactiflux.com/)

## Code Conventions

Expand All @@ -161,4 +193,5 @@ Facebook has a [bounty program](https://www.facebook.com/whitehat/) for the safe

## License

By contributing to Jest, you agree that your contributions will be licensed under its MIT license.
By contributing to Jest, you agree that your contributions will be licensed
under its MIT license.
Loading