Commit Graph

1136 Commits

Author SHA1 Message Date
greenkeeper[bot] ced096c048 chore: Update release-it to the latest version 🚀 (#90)
## The devDependency [release-it](https://github.com/webpro/release-it) was updated from `8.4.3` to `9.0.0`.
This version is **not covered** by your **current version range**.

If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.

---

<details>
<summary>Release Notes for Release 9.0.0</summary>

<ul>
<li>Add updates/changelog notice &amp; remove temp v8 notice (<a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/webpro/release-it/commit/ff75970fbe684bb76842472e5f265b1448d5ac22/hovercard" href="https://urls.greenkeeper.io/webpro/release-it/commit/ff75970fbe684bb76842472e5f265b1448d5ac22"><tt>ff75970</tt></a>)</li>
<li>Add demo for pre-releases (<a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/webpro/release-it/commit/fb9990c6f149ed73285c2fea56858b827aeae78a/hovercard" href="https://urls.greenkeeper.io/webpro/release-it/commit/fb9990c6f149ed73285c2fea56858b827aeae78a"><tt>fb9990c</tt></a>)</li>
</ul>
</details>

<details>
<summary>Commits</summary>
<p>The new version differs by 39 commits ahead by 39, behind by 2.</p>
<ul>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/83f1f883037cd39db9462c59e9692ce60138c542"><code>83f1f88</code></a> <code>Release 9.0.0</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/ff75970fbe684bb76842472e5f265b1448d5ac22"><code>ff75970</code></a> <code>Add updates/changelog notice &amp; remove temp v8 notice</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/fb9990c6f149ed73285c2fea56858b827aeae78a"><code>fb9990c</code></a> <code>Add demo for pre-releases</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/fc1093ef3588f9eb316e69c80bd9ce7461ec0625"><code>fc1093e</code></a> <code>Release 9.0.0-beta.4</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/e4e04a7d103db9d62b493e60b69ce4e9871184b6"><code>e4e04a7</code></a> <code>Fix/clean up dist defaults</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/bc3b137862938327efa0200dbfb98a79667b9e1a"><code>bc3b137</code></a> <code>Indicate pre-release in github prompt</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/867f65c76e5cb1ec34ab1f4148c0a24a9dcca0e9"><code>867f65c</code></a> <code>Fix priority of <code>--npm.tag</code></code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/b15b85604b10851ad7664433c71ac535abf0c108"><code>b15b856</code></a> <code>Release 9.0.0-beta.3</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/7e2e9e712e30a0045a2f1285b7315e40a5dabd18"><code>7e2e9e7</code></a> <code>Minor refactorings</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/ec3e01086976e888cc4205adaea4aaa0ee878032"><code>ec3e010</code></a> <code>Fix npm tag for pre-release</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/3607e706b9cf40651e5d312848f56cba673594db"><code>3607e70</code></a> <code>Add link to repository dependents to readme</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/2ee03e5f1f07e850700ed287babddba03d11d847"><code>2ee03e5</code></a> <code>Update readme with note re. v8/9 (closes #415)</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/0d1ebb5d33da02f8027df062689162a4fa9b949a"><code>0d1ebb5</code></a> <code>Release 9.0.0-beta.2</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/47347c48cdad0321dbb495e1f6fbd7109159e13a"><code>47347c4</code></a> <code>Tweak readme</code></li>
<li><a href="https://urls.greenkeeper.io/webpro/release-it/commit/c0a210b4f8defbff13bc3488798a69c17c8484cf"><code>c0a210b</code></a> <code>Use actual un-mocked method in test</code></li>
</ul>
<p>There are 39 commits in total.</p>
<p>See the <a href="https://urls.greenkeeper.io/webpro/release-it/compare/5e3aec8b3ecb4753f588c2ea0acf3b6313a7c0ed...83f1f883037cd39db9462c59e9692ce60138c542">full diff</a></p>
</details>

<details>
  <summary>FAQ and help</summary>

  There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>

---


Your [Greenkeeper](https://greenkeeper.io) bot 🌴
2018-12-13 15:17:14 +01:00
Brooks Becton ad61c409e9 docs: add website built with Docusaurus (#74)
* Run docusaurus init

* Add api.md and remove initial files

* Run docusaurus init

* Add api.md and remove initial files

* Add callstack info and remove extra scripts

* Commeent out  extra features on home page and Add link to example

* Re Arrange Docs Folder

* add some adjustments

* fix lint

* fix lint
2018-12-11 19:58:37 +01:00
greenkeeper[bot] 1673bc0fdd chore: Update flow-bin to the latest version 🚀 (#86)
## The devDependency [flow-bin](https://github.com/flowtype/flow-bin) was updated from `0.87.0` to `0.88.0`.
This version is **not covered** by your **current version range**.

If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.

---

[Find out more about this release](https://github.com/flowtype/flow-bin).

<details>
  <summary>FAQ and help</summary>

  There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>

---


Your [Greenkeeper](https://greenkeeper.io) bot 🌴
2018-12-10 22:02:59 +01:00
Kacper Wiszczuk 2d999011cc chore: Greenkeeper/@types/react 16.7.11 (#82)
* chore(package): update @types/react to version 16.7.11

* fix: fix typings

* fix: Revert yarn.lock file
2018-12-01 14:20:36 +01:00
Michał Pierzchała dc5ece431c chore: release 1.4.2 v1.4.2 2018-11-29 10:34:50 +01:00
Michał Pierzchała bf2271dc01 fix: add errors for queryBy* helpers when more instances found (#79) 2018-11-29 10:24:22 +01:00
Michał Pierzchała 2981dfe5ed chore: release 1.4.1 v1.4.1 2018-11-28 12:56:57 +01:00
Michał Pierzchała bc4975b481 chore: release 1.4.1-es5.1 2018-11-28 12:51:35 +01:00
Michał Pierzchała c5910d94e4 fix: remove deprecated existential Flow type and use any for now (#77)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

Existential type (`*`) is long deprecated, let's just use `any` for now.

### Test plan

Added some more Flow typings to `shallow.test.js` that were failing because of existential type.
2018-11-28 12:49:15 +01:00
Michał Pierzchała 6dfbc6794b docs: add note about new APIs in v1.4 (#76) 2018-11-28 10:09:48 +01:00
greenkeeper[bot] 0e47320bd4 chore: Update flow-bin to the latest version 🚀 (#75)
## The devDependency [flow-bin](https://github.com/flowtype/flow-bin) was updated from `0.86.0` to `0.87.0`.
This version is **not covered** by your **current version range**.

If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.

---

[Find out more about this release](https://github.com/flowtype/flow-bin).

<details>
  <summary>FAQ and help</summary>

  There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>

---


Your [Greenkeeper](https://greenkeeper.io) bot 🌴
2018-11-28 09:26:15 +01:00
Michał Pierzchała b0c4dd73ad chore(package): update react-native to version 0.57.7 (#73)
* chore(package): update react-native to version 0.57.7

* chore(package): update lockfile yarn.lock
2018-11-27 19:32:19 +01:00
Karl Dominick Cinco b410e39622 fix: modify *ByType API TS typings to allow required props (#71) 2018-11-27 19:28:44 +01:00
Michał Pierzchała 3f2fc16ec2 docs: separate API from main README.md (#70)
### Summary

Separate API docs from main README.md
Relates to #26.

### Test plan

|README.md|api.md|
|--|--|
|<img width="980" alt="screenshot 2018-11-23 at 12 21 42" src="https://user-images.githubusercontent.com/5106466/48941096-740d0a80-ef1a-11e8-8c92-110f1b47826d.png">|<img width="984" alt="screenshot 2018-11-23 at 12 22 05" src="https://user-images.githubusercontent.com/5106466/48941097-740d0a80-ef1a-11e8-872b-a8dfb7814e68.png">|
2018-11-23 15:03:22 +01:00
Michał Pierzchała 2104c486f3 chore: release 1.4.1-es5.0 v1.4.1-es5.0 2018-11-23 10:15:14 +01:00
Jukkish c3672cf23e feat: compile to ES5 for publishing (#50)
### Summary

Fixes https://github.com/callstack/react-native-testing-library/issues/49
2018-11-23 10:07:42 +01:00
Michał Pierzchała a052349ce7 docs: getAllByName -> getAllByType in example (#67)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

Get rid of all `getAllByName` mentions in examples.
2018-11-19 22:28:06 +01:00
Michał Pierzchała 85deb91e3e chore: release 1.4.0 v1.4.0 2018-11-19 18:07:11 +01:00
Michał Pierzchała e407ff07ae feat: deprecate getByName helpers (#66) 2018-11-19 15:16:33 +01:00
Michał Pierzchała 909916e84c feat: add debug to render helpers for easier console debugging (#65)
* feat: add debug to render helpers for easier console debugging

* bring back toJSON to docs

* revert unnecessary change

* update TS

* remove cyclic dependency of debug <-> render
2018-11-19 13:51:38 +01:00
Michał Pierzchała fa198c4037 feat: add getByType helper (#64)
* feat: add getByType helper

* add docs
2018-11-19 13:44:51 +01:00
Michał Pierzchała 235942bee3 fix(breaking): correct faulty implementation of finding by name (#62)
* fix(breaking): correct faulty implementation of finding by name

* chore: update docs

* refactor: code review
2018-11-17 19:13:44 +01:00
greenkeeper[bot] 5b249c3e76 chore: Update release-it to the latest version 🚀 (#63)
* chore(package): update release-it to version 8.0.0

* chore(package): update lockfile yarn.lock
2018-11-17 10:55:10 +01:00
Michał Pierzchała c1eb9a20d3 chore: release 1.3.2 v1.3.2 2018-11-14 14:13:14 +01:00
Michał Pierzchała 01249f6609 Revert "fix: getAllBy* methods return more elements than expected (#57)" (#60)
This reverts commit d6d225d825.
2018-11-14 14:07:43 +01:00
Michał Pierzchała dafad90bb6 chore: release 1.3.1 v1.3.1 2018-11-13 19:47:18 +01:00
Michał Pierzchała 130ab3dd12 chore: update conventional-changelog-cli to version 2.0.11 (#58)
* chore(package): update conventional-changelog-cli to version 2.0.11

* chore(package): update lockfile yarn.lock
2018-11-13 19:42:14 +01:00
greenkeeper[bot] f0dc737dee chore: update flow-bin to the 0.86.0 🚀 (#51)
* chore(package): update flow-bin to version 0.85.0

* chore(package): update lockfile yarn.lock

* update lockfile

* update untyped rn entries
2018-11-13 19:34:57 +01:00
Michał Pierzchała d6d225d825 fix: getAllBy* methods return more elements than expected (#57)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

While upgrading the RN dev dep to 0.57.5 our test suite caught a bug, where `getAllBy*` methods would return more elements than expected. This is fixed by making sure we check the proper type of the parameter when we compare it directly to `node.type` (should be a function, but we allowed strings)

### Test plan

Updated snapshot (yay! RN fixed the display names of View and Text)
2018-11-13 19:26:47 +01:00
greenkeeper[bot] b82e56c3c5 chore: Update react to 16.6.1 🚀 (#54)
* chore(package): update react to version 16.6.1

* chore(package): update react-test-renderer to version 16.6.1

* chore(package): update lockfile yarn.lock
2018-11-09 09:24:41 +01:00
greenkeeper[bot] eb0c220a7f chore: Update metro-react-native-babel-preset to 0.49.0 🚀 (#52)
## The devDependency [metro-react-native-babel-preset](https://github.com/facebook/metro) was updated from `0.48.3` to `0.49.0`.
This version is **not covered** by your **current version range**.

If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.

---

[Find out more about this release](https://github.com/facebook/metro).

<details>
  <summary>FAQ and help</summary>

  There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>

---


Your [Greenkeeper](https://greenkeeper.io) bot 🌴
2018-10-30 18:00:58 +01:00
Shawn Axsom d3146aaf11 docs: Documentation update for The Problem section of the README, clarifying Enzyme capabilities while highlighting more react-native-testing-library benefits (#43) 2018-10-25 11:45:53 +02:00
greenkeeper[bot] 2c68384abc chore: Update react to 16.6.0 🚀 (#45)
* chore(package): update react to version 16.6.0

* chore(package): update react-test-renderer to version 16.6.0

* chore(package): update lockfile yarn.lock

* fix lockfile
2018-10-25 11:45:20 +02:00
greenkeeper[bot] bacbb3ebaa chore: Update flow-bin to the latest version 🚀 (#47)
* chore(package): update flow-bin to version 0.84.0

* chore(package): update lockfile yarn.lock

* fix flow
2018-10-25 11:38:03 +02:00
Ben Styles 174a5d0f76 docs: Remove reference to instance in readme (#42) 2018-10-20 19:48:27 +02:00
Michał Pierzchała 1ed1337362 chore: release 1.3.0 v1.3.0 2018-10-18 10:20:07 +02:00
Michał Pierzchała 6fbbe2cdf5 feat: make debug.deep more usable (#40)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

Make `debug.deep` more usable by allowing it to print arbitrary JSON (and actually any) files. This proves handy when we want to debug async component which we want to snapshot after async operations:

```jsx
const { toJSON, getByName } = render(
  <Button onPress={jest.fn} text="Press me" />
);
fireEvent.press(getByName('TouchableOpacity'));
await flushMicrotasksQueue();

debug.deep(toJSON());
```

### Test plan

added one
2018-10-18 09:13:47 +02:00
Michał Pierzchała 44ca90ced8 chore: release 1.2.0 v1.2.0 2018-10-17 22:14:42 +02:00
Michał Pierzchała 45f45bf1b4 feat: move pretty-format from peer do deps (#39)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

We could also make it an optional dependency and inline-require it inside debug (the only place we use it) but for now I decided to make it a regular dependency, because that's what it is, no point in making users install it directly.

### Test plan

green CI
2018-10-17 22:12:18 +02:00
Michał Pierzchała 22ffe8405b chore: add release-it for release and changelog automation (#38) 2018-10-17 16:18:03 +02:00
Michał Pierzchała f0057bc2f8 v1.1.0 v1.1.0 2018-10-16 22:03:42 +02:00
Michał Pierzchała 05db7bcaac feat: add debug.deep and debug.shallow (#37)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

Adds API proposed by https://github.com/callstack/react-native-testing-library/pull/33#issuecomment-430302079.
Also component output is now highlighted:

<img width="259" alt="screenshot 2018-10-16 at 19 33 25" src="https://user-images.githubusercontent.com/5106466/47035614-c10efb80-d17a-11e8-99ac-00f648880008.png">


### Test plan

Added tests for `debug`.
2018-10-16 21:45:56 +02:00
Michał Pierzchała 03e2c4b0f2 fix: use actual react-native instead of homegrown mocks (#36)
<!-- Please provide enough information so that others can review your pull request. -->
<!-- Keep pull requests small and focused on a single change. -->

### Summary

This actually uncovered some bugs, like lack of `onDoublePress` (lol XD) and enabled us to have better snapshots for deep rendering.

### Test plan

no new tests
2018-10-16 18:51:01 +02:00
Michał Pierzchała 07d3be1c51 feat: add toJSON to render; cleanup shallow (#35)
* feat: add toJSON to render; cleanup shallow

* Remove empty dependencies entry

* revert shallow import

* add docs

* add TS typings
2018-10-16 18:00:54 +02:00
greenkeeper[bot] 61f6895b32 chore: Update @callstack/eslint-config to the latest version 🚀 (#34)
## The devDependency [@callstack/eslint-config](https://github.com/callstack/eslint-config-callstack) was updated from `2.0.0` to `3.0.0`.
This version is **not covered** by your **current version range**.

If you don’t accept this pull request, your project will work just like it did before. However, you might be missing out on a bunch of new features, fixes and/or performance improvements from the dependency update.

---

<details>
<summary>Release Notes for v3.0.0</summary>

<ul>
<li>breaking: update <code>eslint-config-prettier</code> to v3.0.1</li>
<li>breaking: update <code>babel-eslint</code> to v10.0.1</li>
<li>breaking: update <code>eslint-plugin-flowtype</code> to v3.0.0</li>
<li>breaking: require ESLint 5 as peer dependency (because of above mentioned deps bump)</li>
</ul>
</details>

<details>
<summary>Commits</summary>
<p>The new version differs by 6 commits.</p>
<ul>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/79c5f38a5a26b773fb2d8999bad44f7e06070831"><code>79c5f38</code></a> <code>v3.0.0</code></li>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/3201e419a2fb25a1cc68df724c239a78246591f4"><code>3201e41</code></a> <code>breaking: require ESLint 5 as peer dependency</code></li>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/ca82ca09ad4de6d8039e909a11559b92a84b0be9"><code>ca82ca0</code></a> <code>chore: update yarn.lock with latest deps</code></li>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/4528e06ecbd759c328a9825ccc8b6a141ed8ab74"><code>4528e06</code></a> <code>Greenkeeper/initial (#37)</code></li>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/4a73ea786f8bac2d28e0e004f4029d3a594a710f"><code>4a73ea7</code></a> <code>Mention issues with CRA (#33)</code></li>
<li><a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/commit/845b88002ed93415a9d229a07b02d4dced6ef265"><code>845b880</code></a> <code>v2.0.0</code></li>
</ul>
<p>See the <a href="https://urls.greenkeeper.io/callstack/eslint-config-callstack/compare/0c260dafa7c2522ea46ac3f4cb5fc9cfb21b7f9e...79c5f38a5a26b773fb2d8999bad44f7e06070831">full diff</a></p>
</details>

<details>
  <summary>FAQ and help</summary>

  There is a collection of [frequently asked questions](https://greenkeeper.io/faq.html). If those don’t help, you can always [ask the humans behind Greenkeeper](https://github.com/greenkeeperio/greenkeeper/issues/new).
</details>

---


Your [Greenkeeper](https://greenkeeper.io) bot 🌴
2018-10-16 13:57:34 +02:00
Kacper Wiszczuk a066544019 fix: Remove unnecessary flow expression (#31) 2018-10-15 20:57:13 +02:00
Kacper Wiszczuk a39f879288 fix: do not bubble event to root element (#30)
Remove bubbling events to the root element as in the most common use case we pass handler prop to the root element:
```jsx
// That's usually what we do in tests
const tree = render(<SomeElement onPress={mockedHandler} />);

// Unsupported use case
const tree = render(<TouchableOpacity onPress={mockHandler()}><Text>XD</Text></TouchableOpacity>)
```
2018-10-15 17:03:30 +02:00
greenkeeper[bot] 8f89cd51ee Update flow-bin to the latest version 🚀 (#25)
* chore(package): update flow-bin to version 0.83.0

* fix do not use frozen lockfile

* fix update yarn.lock
2018-10-11 22:44:30 +02:00
Michał Pierzchała 70938661ec v1.0.0 v1.0.0 2018-10-11 14:56:03 +02:00
Simen Bekkhus 6097c8f64c chore: fix typos in readme (#22) 2018-10-11 00:10:06 +02:00