-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c9635a9
commit c0973e5
Showing
6 changed files
with
56 additions
and
2 deletions.
There are no files selected for viewing
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
20 changes: 20 additions & 0 deletions
20
test/runtime/samples/attribute-casing-foreign-namespace-compiler-option/_config.js
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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
// Test support for the native namespaces preserving attribute case (eg svelte-native, svelte-nodegui). | ||
|
||
export default { | ||
html: ` | ||
<page horizontalAlignment="center"> | ||
<button textWrap="true" text="button"> | ||
</page> | ||
`, | ||
options: { | ||
hydrate: false // Hydration test will fail as case sensitivity is only handled for svg elements. | ||
}, | ||
compileOptions: { | ||
namespace: 'foreign' | ||
}, | ||
test({ assert, target }) { | ||
const attr = sel => target.querySelector(sel).attributes[0].name; | ||
assert.equal(attr('page'), 'horizontalAlignment'); | ||
assert.equal(attr('button'), 'textWrap'); | ||
} | ||
}; |
3 changes: 3 additions & 0 deletions
3
test/runtime/samples/attribute-casing-foreign-namespace-compiler-option/main.svelte
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 |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<page horizontalAlignment="center"> | ||
<button textWrap="true" text="button"> | ||
</page> |
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