aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authord9k <d9k@ya.ru>2018-05-02 22:27:19 +0300
committerd9k <d9k@ya.ru>2018-05-02 22:27:19 +0300
commitf7affc74eff49e81bbad03134867b79892a198e6 (patch)
treed433cd742e92b24f07dd6159987967b0b4988246
parentb48176ea59c485056b07bd6f01aad5c6407c27d9 (diff)
downloadvalua-f7affc74eff49e81bbad03134867b79892a198e6.tar.gz
valua-f7affc74eff49e81bbad03134867b79892a198e6.tar.bz2
valua-f7affc74eff49e81bbad03134867b79892a198e6.zip
numerical indexes for test data: better understanding
-rw-r--r--valua-test.lua38
1 files changed, 19 insertions, 19 deletions
diff --git a/valua-test.lua b/valua-test.lua
index c12a1a4..fa7f433 100644
--- a/valua-test.lua
+++ b/valua-test.lua
@@ -17,25 +17,25 @@ local function check(val_test, test_value, expected, n)
end
local test_values = {
- "test string!",
- "hey",
- "",
- nil,
- true,
- 42,
- 1337,
- '26/10/1980',
- '10-26-1980',
- '29.02.2014',
- '29/02/2016',
- 'a@a.com',
- 'asd123',
- 5.7,
- {},
- {3,46},
- "<script>alert('boohoo@email.com XSS');</script>",
- "test-123_maria.2@newdomain.wow.movie",
- "10/06/1980 10:32:10"
+ [1] = "test string!",
+ [2] = "hey",
+ [3] = "",
+ [4] = nil,
+ [5] = true,
+ [6] = 42,
+ [7] = 1337,
+ [8] = '26/10/1980',
+ [9] = '10-26-1980',
+ [10] = '29.02.2014',
+ [11] = '29/02/2016',
+ [12] = 'a@a.com',
+ [13] = 'asd123',
+ [14] = 5.7,
+ [15] = {},
+ [16] = {3,46},
+ [17] = "<script>alert('boohoo@email.com XSS');</script>",
+ [18] = "test-123_maria.2@newdomain.wow.movie",
+ [19] = "10/06/1980 10:32:10"
}
local tests = {