From 44b75e4755df5e367ad54c3b1fbf476faebe66e4 Mon Sep 17 00:00:00 2001 From: James Bradbury Date: Thu, 30 Dec 2021 18:22:30 +0000 Subject: [PATCH] add test --- .../input.svelte | 2 ++ .../warnings.json | 32 +++++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 test/validator/samples/a11y-click-events-have-key-events/input.svelte create mode 100644 test/validator/samples/a11y-click-events-have-key-events/warnings.json diff --git a/test/validator/samples/a11y-click-events-have-key-events/input.svelte b/test/validator/samples/a11y-click-events-have-key-events/input.svelte new file mode 100644 index 0000000000..47ba7e60d6 --- /dev/null +++ b/test/validator/samples/a11y-click-events-have-key-events/input.svelte @@ -0,0 +1,2 @@ + +
{} }>
\ No newline at end of file diff --git a/test/validator/samples/a11y-click-events-have-key-events/warnings.json b/test/validator/samples/a11y-click-events-have-key-events/warnings.json new file mode 100644 index 0000000000..67aff7d86f --- /dev/null +++ b/test/validator/samples/a11y-click-events-have-key-events/warnings.json @@ -0,0 +1,32 @@ +[ + { + "code": "a11y-unknown-role", + "end": { + "character": 39, + "column": 39, + "line": 1 + }, + "message": "A11y: on:click should be accompanied by one of the following: on:keyup, on:keydown or on:keypress", + "pos": 0, + "start": { + "character": 0, + "column": 0, + "line": 1 + } + }, + { + "code": "a11y-unknown-role", + "end": { + "character": 73, + "column": 33, + "line": 2 + }, + "message": "A11y: on:click should be accompanied by one of the following: on:keyup, on:keydown or on:keypress", + "pos": 40, + "start": { + "character": 40, + "column": 0, + "line": 2 + } + } +] \ No newline at end of file