-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
merge pull request #25 from mnenie/dev
feat: add vitest modules, resolve #23
- Loading branch information
Showing
14 changed files
with
43 additions
and
41 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
src/shared/ui/badge/__tests__/__snapshots__/UiBadge.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiBadge > should have content at slot 1`] = `"<div class="text-xs _badge_cf2d58 _default_cf2d58">badge</div>"`; | ||
exports[`UiBadge > should have content at slot 1`] = `"<div class="text-xs badge default">badge</div>"`; |
2 changes: 1 addition & 1 deletion
2
src/shared/ui/button/__tests__/__snapshots__/UiButton.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiButton > should have content at slot 1`] = `"<button class="text-sm _button_8511b8 _default_8511b8 _md_8511b8">ui button</button>"`; | ||
exports[`UiButton > should have content at slot 1`] = `"<button class="text-sm button default md">ui button</button>"`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
src/shared/ui/dropdown/__tests__/__snapshots__/UiDropdown.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/shared/ui/input/__tests__/__snapshots__/UiInput.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiInput > should render correctly 1`] = `"<input placeholder="jenda" type="text" class="_input_default_1b38d4 text-sm" autocomplete="on" value="value">"`; | ||
exports[`UiInput > should render correctly 1`] = `"<input placeholder="jenda" type="text" class="input_default text-sm" autocomplete="on" value="value">"`; |
4 changes: 2 additions & 2 deletions
4
src/shared/ui/progress-bar/__tests__/__snapshots__/UiProgressBar.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiProgressBar > should render correctly 1`] = ` | ||
"<div class="_progress_bar_container_aabae5"> | ||
<div class="_progress_bar_active_aabae5"></div> | ||
"<div class="progress_bar_container"> | ||
<div class="progress_bar_active"></div> | ||
</div>" | ||
`; |
4 changes: 1 addition & 3 deletions
4
src/shared/ui/radio-group/__tests__/__snapshots__/UiRadioGroup.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiInput > should render correctly 1`] = `"<input id="radio-input-id" type="radio" class="_radio_item_90e1b5" name="radio-input-name">"`; | ||
exports[`UiRadioGroup > should render correctly 1`] = `"<input id="radio-input-id" type="radio" class="_radio_item_90e1b5" name="radio-input-name">"`; | ||
exports[`UiRadioGroup > should render correctly 1`] = `"<input id="radio-input-id" type="radio" class="radio_item" name="radio-input-name">"`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
src/shared/ui/select/__tests__/__snapshots__/UiSelect.spec.ts.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html | ||
|
||
exports[`UiSelect > should render correctly 1`] = ` | ||
"<div class="_custom_select_b14453"> | ||
<div class="_selected_b14453"><span class="text-sm">test</span><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="var(--zinc-400)" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevrons-up-down-icon"> | ||
"<div class="custom_select"> | ||
<div class="selected"><span class="text-sm">test</span><svg xmlns="http://www.w3.org/2000/svg" width="15" height="15" viewBox="0 0 24 24" fill="none" stroke="var(--zinc-400)" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-chevrons-up-down-icon"> | ||
<path d="m7 15 5 5 5-5"></path> | ||
<path d="m7 9 5-5 5 5"></path> | ||
</svg></div> | ||
<transition-stub name="dropdown" appear="false" persisted="true" css="true"> | ||
<div class="_items_b14453" style=""></div> | ||
<transition-stub name="dropdown" appear="false" persisted="false" css="true"> | ||
<div class="items"></div> | ||
</transition-stub> | ||
</div>" | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,19 @@ | ||
import { fileURLToPath } from 'node:url' | ||
import { mergeConfig, defineConfig, configDefaults } from 'vitest/config' | ||
import viteConfig from './vite.config' | ||
import { fileURLToPath } from 'node:url'; | ||
import { mergeConfig, defineConfig, configDefaults } from 'vitest/config'; | ||
import viteConfig from './vite.config'; | ||
|
||
export default mergeConfig( | ||
viteConfig, | ||
defineConfig({ | ||
test: { | ||
environment: 'jsdom', | ||
exclude: [...configDefaults.exclude, 'e2e/**'], | ||
root: fileURLToPath(new URL('./', import.meta.url)) | ||
root: fileURLToPath(new URL('./', import.meta.url)), | ||
css: { | ||
modules: { | ||
classNameStrategy: 'non-scoped' | ||
} | ||
} | ||
} | ||
}) | ||
) | ||
); |