Skip to content

Commit

Permalink
Merge pull request #10 from deinsoftware/dev
Browse files Browse the repository at this point in the history
removed testing library snippets
  • Loading branch information
equiman authored Apr 4, 2023
2 parents 47cf213 + 6ab8e99 commit 52f2a8a
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 28 deletions.
Binary file modified .github/social/preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,16 @@ Fixed for any bug fixes.
Security to invite users to upgrade in case of vulnerabilities.
-->

## 1.5.0 - 2023/04/03

### Added

- Alias for `it` and `desc`

### Removed

- removed all the Testing Library snippets to a new extension (WIP)

## 1.4.1 - 2023/04/03

### Fixed
Expand Down
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,6 @@ Below is a list of all available snippets and the triggers of each one. The `░
| Trigger | Result |
| -------: | ----------------------------------------------------------------- |
| `iv→` | `import { it, expect, describe } from 'vitest'█` |
| `itl→` | `import { render, screen } from '@testing-library/░<react\|vue>█` |
| `itr→` | `import { render, screen } from '@testing-library/react█` |
| `itv→` | `import { render, screen } from '@testing-library/vue█` |

### Setup

Expand All @@ -99,6 +96,7 @@ Below is a list of all available snippets and the triggers of each one. The `░
| Trigger | Result |
| -------: | ---------------------------------------------------------------------- |
| `d→` | <code>describe('░group', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `desc→` | <code>describe('░group', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `do→` | <code>describe.only('░group', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `ds→` | <code>describe.skip('░group', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |

Expand All @@ -122,9 +120,10 @@ Below is a list of all available snippets and the triggers of each one. The `░
| Trigger | Result |
| -------: | ------------------------------------------------------------------ |
| `i→` | <code>it('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `it→` | <code>it('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `io→` | <code>it.only('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `is→` | <code>it.skip('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `it` | `it.todo('░should')█` |
| `itd` | `it.todo('░should')█` |
| `ia→` | <code>it('░should', async () => {<br/>&nbsp;&nbsp;█<br/>})</code> |

### Test
Expand All @@ -134,7 +133,7 @@ Below is a list of all available snippets and the triggers of each one. The `░
| `t→` | <code>test('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `to→` | <code>test.only('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `ts→` | <code>test.skip('░should', () => {<br/>&nbsp;&nbsp;█<br/>})</code> |
| `tt` | `test.todo('░should')█` |
| `ttd` | `test.todo('░should')█` |
| `ta→` | <code>test('░should', async () => {<br/>&nbsp;&nbsp;█<br/>})</code> |

### Expect
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "vitest-snippets",
"description": "VS Code Vitest snippets for JS and TS",
"version": "1.4.1",
"version": "1.5.0",
"displayName": "Vitest Snippets",
"publisher": "deinsoftware",
"icon": "images/light-icon.png",
Expand Down
2 changes: 1 addition & 1 deletion snippets/describe.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"describe": {
"prefix": "d",
"prefix": ["d", "desc"],
"body": "describe('${1:group}', () => {\n\t$0\n})",
"description": "creates a describe block"
},
Expand Down
20 changes: 0 additions & 20 deletions snippets/import.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,5 @@
"prefix": "iv",
"body": "import { it, expect, describe } from 'vitest'$0",
"description": "essential imports for vitest"
},
"import.testing-library": {
"prefix": "itl",
"body": "import { render, screen } from '@testing-library/${1|react,vue|}'$0",
"description": "essential imports for testing-library"
},
"import.testing-library.react": {
"prefix": "itr",
"body": "import { render, screen } from '@testing-library/react'$0",
"description": "essential imports for testing-library"
},
"import.testing-library.vue": {
"prefix": "itv",
"body": "import { render, screen } from '@testing-library/vue'$0",
"description": "essential imports for testing-library"
},
"import.testing-library.user-event": {
"prefix": "itu",
"body": "import user from '@testing-library/user-event'$0",
"description": "imports user-event for testing-library"
}
}
2 changes: 1 addition & 1 deletion snippets/it.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"it": {
"prefix": "i",
"prefix": ["i", "it"],
"body": "it('${1:should}', () => {\n\t$0\n})",
"description": "creates an it block"
},
Expand Down

0 comments on commit 52f2a8a

Please sign in to comment.