From 128b066f2a39d680bc5bd96e3ad6c841247575b8 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Thu, 21 Nov 2019 14:25:09 -0500 Subject: [PATCH] add test for component with more than 31 dynamic values --- .../samples/bitmask-overflow/_config.js | 97 +++++++++++++++++++ .../samples/bitmask-overflow/main.svelte | 85 ++++++++++++++++ 2 files changed, 182 insertions(+) create mode 100644 test/runtime/samples/bitmask-overflow/_config.js create mode 100644 test/runtime/samples/bitmask-overflow/main.svelte diff --git a/test/runtime/samples/bitmask-overflow/_config.js b/test/runtime/samples/bitmask-overflow/_config.js new file mode 100644 index 0000000000..7d550da056 --- /dev/null +++ b/test/runtime/samples/bitmask-overflow/_config.js @@ -0,0 +1,97 @@ +export default { + html: ` +

0

+

1

+

2

+

3

+

4

+

5

+

6

+

7

+

8

+

9

+

10

+

11

+

12

+

13

+

14

+

15

+

16

+

17

+

18

+

19

+

20

+

21

+

22

+

23

+

24

+

25

+

26

+

27

+

28

+

29

+

30

+

31

+

32

+

33

+

34

+

35

+

36

+

37

+

38

+

39

+

40

+ `, + + test({ assert, component, target }) { + component._0 = 'a'; + component._30 = 'b'; + component._31 = 'c'; + component._32 = 'd'; + component._40 = 'e'; + + assert.htmlEqual(target.innerHTML, ` +

a

+

1

+

2

+

3

+

4

+

5

+

6

+

7

+

8

+

9

+

10

+

11

+

12

+

13

+

14

+

15

+

16

+

17

+

18

+

19

+

20

+

21

+

22

+

23

+

24

+

25

+

26

+

27

+

28

+

29

+

b

+

c

+

d

+

33

+

34

+

35

+

36

+

37

+

38

+

39

+

e

+ `); + } +}; \ No newline at end of file diff --git a/test/runtime/samples/bitmask-overflow/main.svelte b/test/runtime/samples/bitmask-overflow/main.svelte new file mode 100644 index 0000000000..20216786c2 --- /dev/null +++ b/test/runtime/samples/bitmask-overflow/main.svelte @@ -0,0 +1,85 @@ + + +

{_0}

+

{_1}

+

{_2}

+

{_3}

+

{_4}

+

{_5}

+

{_6}

+

{_7}

+

{_8}

+

{_9}

+

{_10}

+

{_11}

+

{_12}

+

{_13}

+

{_14}

+

{_15}

+

{_16}

+

{_17}

+

{_18}

+

{_19}

+

{_20}

+

{_21}

+

{_22}

+

{_23}

+

{_24}

+

{_25}

+

{_26}

+

{_27}

+

{_28}

+

{_29}

+

{_30}

+

{_31}

+

{_32}

+

{_33}

+

{_34}

+

{_35}

+

{_36}

+

{_37}

+

{_38}

+

{_39}

+

{_40}

\ No newline at end of file