diff --git a/.all-contributorsrc b/.all-contributorsrc
index a4c7d8fb..f382cca7 100644
--- a/.all-contributorsrc
+++ b/.all-contributorsrc
@@ -178,7 +178,8 @@
"avatar_url": "https://avatars2.githubusercontent.com/u/21194045?s=400&v=4",
"profile": "https://github.com/thchia",
"contributions": [
- "bug"
+ "bug",
+ "code"
]
},
{
diff --git a/README.md b/README.md
index c26dd328..10a63b26 100644
--- a/README.md
+++ b/README.md
@@ -682,7 +682,7 @@ Thanks goes to these people ([emoji key][emojis]):
| [
Kent C. Dodds](https://kentcdodds.com)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=kentcdodds "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=kentcdodds "Documentation") [π](#infra-kentcdodds "Infrastructure (Hosting, Build-Tools, etc)") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=kentcdodds "Tests") | [
Ryan Castner](http://audiolion.github.io)
[π](https://github.com/kentcdodds/dom-testing-library/commits?author=audiolion "Documentation") | [
Daniel Sandiego](https://www.dnlsandiego.com)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=dnlsandiego "Code") | [
PaweΕ MikoΕajczyk](https://github.com/Miklet)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=Miklet "Code") | [
Alejandro ΓÑñez Ortiz](http://co.linkedin.com/in/alejandronanez/)
[π](https://github.com/kentcdodds/dom-testing-library/commits?author=alejandronanez "Documentation") | [
Matt Parrish](https://github.com/pbomb)
[π](https://github.com/kentcdodds/dom-testing-library/issues?q=author%3Apbomb "Bug reports") [π»](https://github.com/kentcdodds/dom-testing-library/commits?author=pbomb "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=pbomb "Documentation") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=pbomb "Tests") | [
Justin Hall](https://github.com/wKovacs64)
[π¦](#platform-wKovacs64 "Packaging/porting to new platform") |
| :---: | :---: | :---: | :---: | :---: | :---: | :---: |
| [
Anto Aravinth](https://github.com/antoaravinth)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=antoaravinth "Code") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=antoaravinth "Tests") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=antoaravinth "Documentation") | [
Jonah Moses](https://github.com/JonahMoses)
[π](https://github.com/kentcdodds/dom-testing-library/commits?author=JonahMoses "Documentation") | [
Εukasz Gandecki](http://team.thebrain.pro)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=lgandecki "Code") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=lgandecki "Tests") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=lgandecki "Documentation") | [
Ivan Babak](https://sompylasar.github.io)
[π](https://github.com/kentcdodds/dom-testing-library/issues?q=author%3Asompylasar "Bug reports") [π€](#ideas-sompylasar "Ideas, Planning, & Feedback") [π»](https://github.com/kentcdodds/dom-testing-library/commits?author=sompylasar "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=sompylasar "Documentation") | [
Jesse Day](https://github.com/jday3)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=jday3 "Code") | [
Ernesto GarcΓa](http://gnapse.github.io)
[π¬](#question-gnapse "Answering Questions") [π»](https://github.com/kentcdodds/dom-testing-library/commits?author=gnapse "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=gnapse "Documentation") | [
Josef Maxx Blake](http://jomaxx.com)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=jomaxx "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=jomaxx "Documentation") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=jomaxx "Tests") |
-| [
Alex Cook](https://github.com/alecook)
[π](https://github.com/kentcdodds/dom-testing-library/commits?author=alecook "Documentation") [π‘](#example-alecook "Examples") | [
Daniel Cook](https://github.com/dfcook)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Documentation") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Tests") | [
Thomas Chia](https://github.com/thchia)
[π](https://github.com/kentcdodds/dom-testing-library/issues?q=author%3Athchia "Bug reports") | [
Tim Deschryver](https://github.com/tdeschryver)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=tdeschryver "Code") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=tdeschryver "Tests") |
+| [
Alex Cook](https://github.com/alecook)
[π](https://github.com/kentcdodds/dom-testing-library/commits?author=alecook "Documentation") [π‘](#example-alecook "Examples") | [
Daniel Cook](https://github.com/dfcook)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Code") [π](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Documentation") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=dfcook "Tests") | [
Thomas Chia](https://github.com/thchia)
[π](https://github.com/kentcdodds/dom-testing-library/issues?q=author%3Athchia "Bug reports") [π»](https://github.com/kentcdodds/dom-testing-library/commits?author=thchia "Code") | [
Tim Deschryver](https://github.com/tdeschryver)
[π»](https://github.com/kentcdodds/dom-testing-library/commits?author=tdeschryver "Code") [β οΈ](https://github.com/kentcdodds/dom-testing-library/commits?author=tdeschryver "Tests") |
diff --git a/src/__tests__/element-queries.js b/src/__tests__/element-queries.js
index bd2e8343..30601751 100644
--- a/src/__tests__/element-queries.js
+++ b/src/__tests__/element-queries.js
@@ -48,6 +48,14 @@ test('can get elements by matching their text content', () => {
expect(queryByText('Step 1 of 4')).toBeInTheDOM()
})
+test('matches case with RegExp matcher', () => {
+ const {queryByText} = render(`
+ STEP 1 of 4
+ `)
+ expect(queryByText(/STEP 1 of 4/)).toBeInTheDOM()
+ expect(queryByText(/Step 1 of 4/)).not.toBeInTheDOM()
+})
+
test('get can get form controls by label text', () => {
const {getByLabelText} = render(`