From 41cb10a3cb9261eb6d3b4f0579ade411d2de1a2d Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Fri, 5 Mar 2021 23:03:08 -0500 Subject: test subparameter behavior --- tests/data/fixtures/colors.in | 3 +++ tests/data/fixtures/colors/20.json | 8 ++++++++ tests/data/fixtures/colors/20.typescript | 1 + tests/data/fixtures/colors/21.json | 21 +++++++++++++++++++++ tests/data/fixtures/colors/21.typescript | 1 + tests/data/fixtures/colors/22.json | 31 +++++++++++++++++++++++++++++++ tests/data/fixtures/colors/22.typescript | 1 + 7 files changed, 66 insertions(+) create mode 100644 tests/data/fixtures/colors/20.json create mode 100644 tests/data/fixtures/colors/20.typescript create mode 100644 tests/data/fixtures/colors/21.json create mode 100644 tests/data/fixtures/colors/21.typescript create mode 100644 tests/data/fixtures/colors/22.json create mode 100644 tests/data/fixtures/colors/22.typescript diff --git a/tests/data/fixtures/colors.in b/tests/data/fixtures/colors.in index 3b422fb..59da023 100644 --- a/tests/data/fixtures/colors.in +++ b/tests/data/fixtures/colors.in @@ -17,3 +17,6 @@ a\x1b[38;5;123mb\x1b[48;5;158mc \x1bcfoo \x1b[1;2H\x1b[41mo\x1b[m \x1b[1;1H\x1b[41m\x1b[X\x1b[m +\x1b[m\x1b[2J\x1b[H +a\x1b[38:5:123mb\x1b[48:5:158mc +\x1b[38:2:50:75:100md\x1b[48:2:125:150:175me diff --git a/tests/data/fixtures/colors/20.json b/tests/data/fixtures/colors/20.json new file mode 100644 index 0000000..bb83ae4 --- /dev/null +++ b/tests/data/fixtures/colors/20.json @@ -0,0 +1,8 @@ +{ + "contents": "", + "cells": {}, + "cursor_position": [ + 0, + 0 + ] +} \ No newline at end of file diff --git a/tests/data/fixtures/colors/20.typescript b/tests/data/fixtures/colors/20.typescript new file mode 100644 index 0000000..c46ac5f --- /dev/null +++ b/tests/data/fixtures/colors/20.typescript @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/tests/data/fixtures/colors/21.json b/tests/data/fixtures/colors/21.json new file mode 100644 index 0000000..a7a7ec6 --- /dev/null +++ b/tests/data/fixtures/colors/21.json @@ -0,0 +1,21 @@ +{ + "contents": "abc", + "cells": { + "0,0": { + "contents": "a" + }, + "0,1": { + "contents": "b", + "fgcolor": "123" + }, + "0,2": { + "contents": "c", + "fgcolor": "123", + "bgcolor": "158" + } + }, + "cursor_position": [ + 0, + 3 + ] +} \ No newline at end of file diff --git a/tests/data/fixtures/colors/21.typescript b/tests/data/fixtures/colors/21.typescript new file mode 100644 index 0000000..b9ce486 --- /dev/null +++ b/tests/data/fixtures/colors/21.typescript @@ -0,0 +1 @@ +a[38:5:123mb[48:5:158mc \ No newline at end of file diff --git a/tests/data/fixtures/colors/22.json b/tests/data/fixtures/colors/22.json new file mode 100644 index 0000000..f4fa9fb --- /dev/null +++ b/tests/data/fixtures/colors/22.json @@ -0,0 +1,31 @@ +{ + "contents": "abcde", + "cells": { + "0,0": { + "contents": "a" + }, + "0,1": { + "contents": "b", + "fgcolor": "123" + }, + "0,2": { + "contents": "c", + "fgcolor": "123", + "bgcolor": "158" + }, + "0,3": { + "contents": "d", + "fgcolor": "#324b64", + "bgcolor": "158" + }, + "0,4": { + "contents": "e", + "fgcolor": "#324b64", + "bgcolor": "#7d96af" + } + }, + "cursor_position": [ + 0, + 5 + ] +} \ No newline at end of file diff --git a/tests/data/fixtures/colors/22.typescript b/tests/data/fixtures/colors/22.typescript new file mode 100644 index 0000000..32ab7e4 --- /dev/null +++ b/tests/data/fixtures/colors/22.typescript @@ -0,0 +1 @@ +[38:2:50:75:100md[48:2:125:150:175me \ No newline at end of file -- cgit v1.2.3-54-g00ecf