testing_data 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/testing_data.rb +47 -0
  3. metadata +43 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: d5c662431b01397eb13623b1d9fbd6314b235bb8ec200a370686f3584cb3755b
4
+ data.tar.gz: 9113582b88765af8821d7d3ab98db6188d4a374e53895a5c0e8bc1d105ebc939
5
+ SHA512:
6
+ metadata.gz: dd3ee9ca0fc7603f6e5327b3328e0546cd765a839351fff3785cc8e76b5195daa92eb13614ed850b7b99ce8185146f61d77c3cabfab5f2d21b6f7cc5e4f3c79f
7
+ data.tar.gz: 8adc54ae4d0dea40de102808777241f1de951199701f26f7d6ca28fd7c920181b0803dbc216fee71b1bc2af3a5905ddcfb6b7b8b0854b6521930fa84faa2d578
@@ -0,0 +1,47 @@
1
+ module TestingData
2
+ class Error < StandardError; end
3
+ Cli = ['-', '--', '--version', '--help', '$USER', '/dev/null; touch /tmp/blns.fail ; echo', '`touch /tmp/blns.fail`', '$(touch /tmp/blns.fail)',' @{[system "touch /tmp/blns.fail"]}']
4
+ Email = ['plainaddress', '#@%^%#$@#$@#.com', '@domain.com', 'Joe Smith <email@domain.com>', 'email.domain.com', 'email@domain@domain.com', '.email@domain.com', 'email.@domain.com', 'email..email@domain.com', 'あいうえお@domain.com', 'email@domain.com (Joe Smith)', 'email@domain', 'email@-domain.com', 'email@domain.web', 'email@111.222.333.44444', 'email@domain..com' ]
5
+ Emote1 = ['ヽ༼ຈل͜ຈ༽ノ ヽ༼ຈل͜ຈ༽ノ', '(。◕ ∀ ◕。)', '`ィ(´∀`∩', '__ロ(,_,*)', '・( ̄∀ ̄)・:*:', '゚・✿ヾ╲(。◕‿◕。)╱✿・゚', ',。・:*:・゜’( ☻ ω ☻ )。・:*:・゜’', '(╯°□°)╯︵ ┻━┻)', '(ノಥ益ಥ)ノ ┻━┻', '┬─┬ノ( º _ ºノ)', '( ͡° ͜ʖ ͡°)', '¯\_(ツ)_/¯']
6
+ Emote2 = ['😍', '👩🏽', '👾 🙇 💁 🙅 🙆 🙋 🙎 🙍', '🐵 🙈 🙉 🙊', '❤️ 💔 💌 💕 💞 💓 💗 💖 💘 💝 💟 💜 💛 💚 💙', '✋🏿 💪🏿 👐🏿 🙌🏿 👏🏿 🙏🏿', '🚾 🆒 🆓 🆕 🆖 🆗 🆙 🏧']
7
+ Int = [0, -0, -0.0, 0.00, 1, 1.00, -1, -1.00, 01000, -2147483648/-1, -9223372036854775808/-1, 999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999, '$1.00', '1/2', '1E2', '1E02', '1E+02', '-$1.00', '-1/2', '-1E2', '-1E02', '-1E+02', '1/0', '0/0', '+0', '+0.0', '0..0', '.', '0.0.0', '0,00', '0,,0', ',', '0,0,0', '0.0/0', '1.0/0.0', '0.0/0.0', '1,0/0,0', '0,0/0,0', '--1', '-', '-.', '-,', 'NaN', 'Infinity', '-Infinity', 'INF', '1#INF', '-1#IND', '1#QNAN', '1#SNAN', '1#IND', '0x0', '0xffffffff', '0xffffffffffffffff', '0xabad1dea', '1\'23456789012345678901234567890123456789', '1,000.00', '1 000.00', '1\'000.00', '1,000,000.00', '1 000 000.00', '1\'000\'000.00', '1.000,00', '1 000,00', '1\'000,00', '1.000.000,00', '1 000 000,00', '1\'000\'000,00', '08', '09', '2.2250738585072011e-308']
8
+ Ios = ['Powerلُلُصّبُلُلصّبُررً ॣ ॣh ॣ ॣ冗', 'జ్ఞ‌ా', '🏳0🌈️']
9
+ Reverse = ['أنا أكتب باللغة العربية', 'אני כותב בעברית', 'میں urdu میں لکھ رہا ہوں', 'እኔ በመጻፍ እማሬ ነው']
10
+ Rude = ['Scunthorpe General Hospital', 'Penistone Community Church', 'Lightwater Country Park', 'Jimmy Clitheroe', 'Horniman Museum', 'shitake mushrooms', 'RomansInSussex.co.uk', 'http://www.cum.qc.ca/', 'Craig Cockburn', 'Linda Callahan', 'Dr. Herman I. Libshitz', 'magna cum laude', 'Super Bowl XXX', 'medieval erection of parapets', 'evaluate', 'mocha', 'expression', 'Arsenal canal', 'classic', 'Tyson Gay', 'Dick Van Dyke', 'basement']
11
+ Sql = ['1;DROP TABLE users', '1\'; DROP TABLE users-- 1', '\' OR 1=1 -- 1', '\' OR \'1\'=\'1', '%', '_']
12
+ Scripts = ['<script>alert(123)</script>', '&lt;script&gt;alert(&#39;123&#39;);&lt;/script&gt;', '<img src=x onerror=alert(123) />', '<svg><script>123<1>alert(123)</script>', '"><script>alert(123)</script>', '\'><script>alert(123)</script>', '><script>alert(123)</script>', '</script><script>alert(123)</script>', '< / script >< script >alert(123)< / script >', 'onfocus=JaVaSCript:alert(123) autofocus', '" onfocus=JaVaSCript:alert(123) autofocus', '\' onfocus=JaVaSCript:alert(123) autofocus', '<script>alert(123)</script>', '<sc<script>ript>alert(123)</sc</script>ript>', '--><script>alert(123)</script>', '";alert(123);t="', '\';alert(123);t=\'', 'JavaSCript:alert(123)', '\';\'alert(123);', 'src=JaVaSCript:prompt(132)', '"><script>alert(123);</script x="', '\'><script>alert(123);</script x=\'', '><script>alert(123);</script x=', '" autofocus onkeyup="javascript:alert(123)', '\' autofocus onkeyup=\'javascript:alert(123)']
13
+ Subscript = ['⁰⁴⁵', '₀₁₂', '⁰⁴⁵₀₁₂', 'ด้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็ ด้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็ ด้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็็้้้้้้้้็็็็็้้้้้็็็็']
14
+ Text = ['undefined', 'undef', 'null', 'NULL', '(null)', 'nil', 'NIL', 'true', 'false', 'True', 'False' 'TRUE', 'FALSE', 'None', 'hasOwnProperty', 'then', '\\']
15
+ Twobytechar = ['田中さんにあげて下さい', 'パーティーへ行かないか', '和製漢語', '部落格', '사회과학원 어학연구소', '찦차를 타고 온 펲시맨과 쑛다리 똠방각하', '社會科學院語學研究所', '울란바토르', '𠜎𠜱𠝹𠱓𠱸𠲖𠳏']
16
+ Unicode = ['Ω≈ç√∫˜µ≤≥÷', 'åß∂ƒ©˙∆˚¬…æ', 'œ∑´®†¥¨ˆøπ“‘', '¡™£¢∞§¶•ªº–≠', '˛Ç◊ı˜Â¯˘¿', 'ÅÍÎÏ˝ÓÔÒÚÆ☃', 'Œ„´‰ˇÁ¨ˆØ∏”’', '`⁄€‹›fifl‡°·‚—±', '⅛⅜⅝⅞', 'ЁЂЃЄЅІЇЈЉЊЋЌЍЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя', '٠١٢٣٤٥٦٧٨٩']
17
+ Zalgo = ['Y̙̜͕o̠̠ͅu̮͕̦̗̩̣͍̥r̹̞̖̺͖ ̣͎̜̳͎̺̟s̠̬̟̫̲͓̝͕t͖̣̭̯͓̟ͅr̝̳͇i͖̗̜̲n̮͙g͈̰s̙͖̻̲͔̪ ̬̭̺̜̩̹a̹̭̮͉͕͈͇̬r̫̼̗̗͎e͉̞͉̳ ̪̥̠̻͈̣ͅl̯̖̰̼̱͖̹e͓̥a̤̯͙̠k̞͓̣i͓̞͙̦̼ͅn̪̻̥̞͕̯g͎̲ ̱̫̟̠', 'W̴ͦ̋ͥ̿͒͛̅ͥ̉̊̀͗̋ͦͤ̀̈́͛͜͏̧̛̝̯͔̻h̡̗͖̲̳̗͓̰̙̯ͩ̊̍̈ͬ͛̅̕a̷̰̝̜̪̼̙̙̦̱̣̩̥͍̰͆ͬ̿ͦͭ͗̈͑͋͡t̨̹̩̭̮̦͈͓̥̟̻̫̜̃̒̋͛̏ͨ̋ ̘͓̗̳̮̬̳͖̰͉̥̗̳̲͖̋ͮͭͥ͋̆̃ͭͨ̎̾͡a̸̧̛̼̰͔̥̪͇͓̭͍̱̠̻̦̥̝͛͆̾̐̔̾ͦ̇̈́ͫ̍̃͂ͫ̔̎͗ ̛ͨ̏ͭ̈́̔̈́̾͊ͨ̆͐̌ͬ͢҉̴̗͍̪̠̱̗̲̙͍̟̪̹͕̮͍̬̞m̢̢̗̳̰͇̺͉̣̩͖͈͎̪̲̘͉̣͙̘̈͒̄̄̊̅ͫͥ͆͐ͬ́̇̐̇̾̎̕e͊̃ͩ̇̎͛̀͢͏̝͈̻̺͙͎̦̭͡s̷̸̢̰̞͚̞̞̮͎͔̗̩͈̙̥̜͆͑ͦ̈͗̇̍ͫͦͮͤ̈́̋ͧ̌̉̂̕͜s̸̈́̌̆̐̽̍̓͒͐҉̮̬̠͚̀', '1̮̰̝̻̻͖̀̓̂3͌̐̿̀̕3̰̻̰̙̓̌̋́̚7̍̒̽̀']
18
+
19
+ All = { CLI: Cli, EMAIL: Email, EMOTE1: Emote1, EMOTE2: Emote2, INT: Int, IOS: Ios, RUDE: Rude, REVERSE: Reverse, SQL: Sql, SCRIPTS: Scripts, SUBSCRIPT: Subscript, TEXT: Text, TWOBYTECHAR: Twobytechar, UNICODE: Unicode, ZALGO: Zalgo }
20
+
21
+
22
+ def feed(type)
23
+ type.downcase!
24
+ type.capitalize!
25
+ case type
26
+ when 'All' then All
27
+ when 'Cli' then Cli
28
+ when 'Email' then Email
29
+ when 'Emote1' then Emote1
30
+ when 'Emote2' then Emote2
31
+ when 'Int' then Int
32
+ when 'Ios' then Ios
33
+ when 'Reverse' then Reverse
34
+ when 'Rude' then Rude
35
+ when 'Sql' then SQL
36
+ when 'Scripts' then Scripts
37
+ when 'Subscript' then Subscript
38
+ when 'Text' then Text
39
+ when 'Twobytechar' then Twobytechar
40
+ when 'Unicode' then Unicode
41
+ when 'Zalgo' then Zalgo
42
+ else return '["Please request a valid data type"]'
43
+ end
44
+ end
45
+ end
46
+
47
+
metadata ADDED
@@ -0,0 +1,43 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: testing_data
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Niall47
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2019-07-05 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description:
14
+ email:
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - lib/testing_data.rb
20
+ homepage:
21
+ licenses:
22
+ - MIT
23
+ metadata: {}
24
+ post_install_message:
25
+ rdoc_options: []
26
+ require_paths:
27
+ - lib
28
+ required_ruby_version: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ required_rubygems_version: !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ requirements: []
39
+ rubygems_version: 3.0.4
40
+ signing_key:
41
+ specification_version: 4
42
+ summary: Feeds arrays of bad test data
43
+ test_files: []