allow negative assertion in injection tests (#4107)

* tests(vue, svelte): strengthen tests

* fix(html, vue, svelte): fix wrong test format

* allow negative assertions in injection tests
This commit is contained in:
lucario387 2023-01-07 19:22:20 +09:00 committed by GitHub
parent 0922634d37
commit 85d9534491
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 84 additions and 135 deletions

View file

@ -1,29 +1,14 @@
<script>
import Button from "./Button.svelte";
// ^ javascript
</script>
<script lang="ts">
const foo: number = 1
// ^ typescript
</script>
<script> import Button from "./Button.svelte"; </script>
<!-- ^ javascript -->
<script lang="ts"> const foo: number = 1 </script>
<!-- ^ typescript -->
<!-- ^ !javascript -->
<style>
main {
font-family: sans-serif;
text-align: center;
/* ^ css
*/
}
</style>
<style lang="scss">
main {
font-family: sans-serif;
text-align: center;
&:hover {
// ^ scss
}
}
</style>
<style> main { font-family: sans-serif; text-align: center; } </style>
<!-- ^ css -->
<style lang="scss"> main { &:hover { } } </style>
<!-- ^ scss -->
<!-- ^ !css -->
<main>
<h1>Test file</h1>