flok 0.0.12 → 0.0.14

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 (867) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +17 -4
  3. data/Rakefile +76 -10
  4. data/app/drivers/chrome/README.md +37 -22
  5. data/app/drivers/chrome/Rakefile +77 -3
  6. data/app/drivers/chrome/build_context.rb +17 -0
  7. data/app/drivers/chrome/cakery/spec.js.erb +11 -0
  8. data/app/drivers/chrome/config.yml +18 -3
  9. data/app/drivers/chrome/pipe.rb +70 -0
  10. data/app/drivers/chrome/spec/config/config.js +39 -0
  11. data/app/drivers/chrome/spec/init/qunit.js +3828 -0
  12. data/app/drivers/chrome/spec/spec/controller_debug_spec.js +16 -0
  13. data/app/drivers/chrome/spec/spec/debug_spec.js +18 -0
  14. data/app/drivers/chrome/spec/spec/sel_scope_spec.js +160 -0
  15. data/app/drivers/chrome/spec/spec/vars_spec.js +28 -0
  16. data/app/drivers/chrome/src/bench.js +19 -0
  17. data/app/drivers/chrome/src/controller.js +164 -0
  18. data/app/drivers/chrome/src/debug.js +75 -0
  19. data/app/drivers/chrome/src/dispatch.js +52 -0
  20. data/app/drivers/chrome/src/event.js +10 -0
  21. data/app/drivers/chrome/src/helpers.js +4 -4
  22. data/app/drivers/chrome/src/net.js +8 -36
  23. data/app/drivers/chrome/src/segue.js +18 -0
  24. data/app/drivers/chrome/src/sockio.js +34 -0
  25. data/app/drivers/chrome/src/timer.js +9 -0
  26. data/app/drivers/chrome/src/ui.js +192 -87
  27. data/app/drivers/chrome/src/vendor/socket.io.js +3 -0
  28. data/app/kern/controller.js +116 -0
  29. data/app/kern/dispatch.js +171 -0
  30. data/app/kern/macro.rb +24 -0
  31. data/{output.js → app/kern/mod/controller.js} +0 -0
  32. data/app/kern/mod/debug.js +120 -0
  33. data/app/kern/mod/event.js +29 -0
  34. data/app/kern/mod/net.js +17 -0
  35. data/app/kern/mod/segue.js +36 -0
  36. data/app/kern/mod/sockio.js +1 -0
  37. data/app/kern/mod/ui.js +2 -0
  38. data/app/kern/net_cb.js +25 -0
  39. data/app/kern/services/rest.rb +310 -0
  40. data/app/kern/services/timer.rb +30 -0
  41. data/app/kern/tel.js +40 -0
  42. data/bin/flok +61 -17
  43. data/docs/architecture.md +3 -15
  44. data/docs/client_api.md +21 -0
  45. data/docs/compilation.md +31 -5
  46. data/docs/controllers.md +97 -0
  47. data/docs/datatypes.md +42 -0
  48. data/docs/debug_server.md +17 -0
  49. data/docs/drivers.md +52 -0
  50. data/docs/images/flok_arch.png +0 -0
  51. data/docs/images/ui_surface_and_views.png +0 -0
  52. data/docs/images/view_and_spot.png +0 -0
  53. data/docs/interactive.md +35 -0
  54. data/docs/kernel_api.md +37 -0
  55. data/docs/messaging.md +110 -0
  56. data/docs/mod/controller.md +35 -0
  57. data/docs/mod/debug.md +32 -0
  58. data/docs/mod/debug/dump_ui.md +64 -0
  59. data/docs/mod/event.md +16 -0
  60. data/docs/mod/net.md +21 -0
  61. data/docs/mod/persist.md +36 -0
  62. data/docs/mod/sockio.md +13 -0
  63. data/docs/mod/timer.md +8 -0
  64. data/docs/mod/ui.md +40 -0
  65. data/docs/modules.md +9 -0
  66. data/docs/project.md +40 -0
  67. data/docs/project_layout.md +8 -5
  68. data/docs/rakefile.md +13 -0
  69. data/docs/scheduling.md +45 -0
  70. data/docs/services.md +74 -0
  71. data/docs/services/rest.md +21 -0
  72. data/docs/services/timer.md +21 -0
  73. data/docs/testing.md +80 -1
  74. data/flok.gemspec +4 -0
  75. data/lib/flok.rb +6 -0
  76. data/lib/flok/build.rb +75 -26
  77. data/lib/flok/interactive.rb +58 -0
  78. data/lib/flok/platform.rb +32 -0
  79. data/lib/flok/project.rb +63 -0
  80. data/lib/flok/project_template/Gemfile.erb +2 -0
  81. data/lib/flok/project_template/app/controllers/controller.rb +1 -0
  82. data/lib/flok/service_compiler_templates/services.js.erb +13 -0
  83. data/lib/flok/services_compiler.rb +94 -0
  84. data/lib/flok/user_compiler.rb +295 -0
  85. data/lib/flok/user_compiler_templates/ctable.js.erb +33 -0
  86. data/lib/flok/utilities.rb +16 -0
  87. data/lib/flok/version.rb +1 -1
  88. data/logo.png +0 -0
  89. data/opt/clojure/compiler.jar +0 -0
  90. data/opt/clojure/flokjure +53 -0
  91. data/opt/clojure/main.js +13 -0
  92. data/spec/env/etc.rb +2 -0
  93. data/spec/env/iface.rb +64 -0
  94. data/spec/env/kern.rb +128 -0
  95. data/spec/etc/cli_spec.rb +117 -0
  96. data/spec/etc/lib/build_spec.rb +188 -0
  97. data/spec/etc/lib/platform_spec.rb +33 -0
  98. data/spec/etc/lib/project_spec.rb +25 -0
  99. data/spec/etc/macro_spec.rb +35 -0
  100. data/spec/etc/service_compiler/service0.rb +10 -0
  101. data/spec/etc/services_compiler_spec.rb +41 -0
  102. data/spec/etc/user_compiler/controller0.rb +14 -0
  103. data/spec/etc/user_compiler_spec.rb +68 -0
  104. data/spec/iface/driver/assets/debug_socket_server.js +42 -0
  105. data/spec/iface/driver/assets/node_modules/socket.io/.npmignore +4 -0
  106. data/spec/iface/driver/assets/node_modules/socket.io/.travis.yml +16 -0
  107. data/spec/iface/driver/assets/node_modules/socket.io/History.md +491 -0
  108. data/spec/iface/driver/assets/node_modules/socket.io/LICENSE +22 -0
  109. data/spec/iface/driver/assets/node_modules/socket.io/Makefile +15 -0
  110. data/spec/iface/driver/assets/node_modules/socket.io/Readme.md +374 -0
  111. data/spec/iface/driver/assets/node_modules/socket.io/index.js +2 -0
  112. data/spec/iface/driver/assets/node_modules/socket.io/lib/client.js +247 -0
  113. data/spec/iface/driver/assets/node_modules/socket.io/lib/index.js +379 -0
  114. data/spec/iface/driver/assets/node_modules/socket.io/lib/namespace.js +242 -0
  115. data/spec/iface/driver/assets/node_modules/socket.io/lib/socket.js +449 -0
  116. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/.jshintrc +3 -0
  117. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/.npmignore +6 -0
  118. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/History.md +157 -0
  119. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/Makefile +33 -0
  120. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/Readme.md +156 -0
  121. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/browser.js +147 -0
  122. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/component.json +19 -0
  123. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/debug.js +197 -0
  124. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/node.js +209 -0
  125. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/node_modules/ms/.npmignore +5 -0
  126. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/node_modules/ms/README.md +33 -0
  127. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/node_modules/ms/index.js +111 -0
  128. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/node_modules/ms/package.json +46 -0
  129. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/debug/package.json +73 -0
  130. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/.npmignore +6 -0
  131. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/.travis.yml +7 -0
  132. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/History.md +408 -0
  133. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/Makefile +23 -0
  134. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/README.md +517 -0
  135. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/index.js +4 -0
  136. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/engine.io.js +126 -0
  137. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/server.js +391 -0
  138. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/socket.js +393 -0
  139. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transport.js +114 -0
  140. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transports/index.js +36 -0
  141. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transports/polling-jsonp.js +108 -0
  142. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transports/polling-xhr.js +101 -0
  143. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transports/polling.js +279 -0
  144. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/lib/transports/websocket.js +110 -0
  145. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/base64id/.npmignore +3 -0
  146. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/base64id/README.md +18 -0
  147. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/base64id/lib/base64id.js +103 -0
  148. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/base64id/package.json +48 -0
  149. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/.jshintrc +3 -0
  150. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/.npmignore +6 -0
  151. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/History.md +132 -0
  152. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/Makefile +33 -0
  153. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/Readme.md +153 -0
  154. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/browser.js +144 -0
  155. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/component.json +19 -0
  156. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/debug.js +197 -0
  157. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/node.js +129 -0
  158. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/node_modules/ms/.npmignore +5 -0
  159. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/node_modules/ms/README.md +33 -0
  160. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/node_modules/ms/index.js +111 -0
  161. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/node_modules/ms/package.json +46 -0
  162. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/debug/package.json +71 -0
  163. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/.npmignore +17 -0
  164. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/.travis.yml +45 -0
  165. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/.zuul.yml +18 -0
  166. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/History.md +100 -0
  167. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/LICENSE +22 -0
  168. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/Makefile +26 -0
  169. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/Readme.md +202 -0
  170. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/index.js +2 -0
  171. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/lib/browser.js +594 -0
  172. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/lib/index.js +467 -0
  173. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/lib/keys.js +19 -0
  174. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/.npmignore +2 -0
  175. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/.travis.yml +5 -0
  176. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/LICENCE +19 -0
  177. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/README.md +75 -0
  178. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/index.js +28 -0
  179. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/package.json +62 -0
  180. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/after/test/after-test.js +120 -0
  181. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/.npmignore +17 -0
  182. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/Makefile +8 -0
  183. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/README.md +17 -0
  184. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/index.js +29 -0
  185. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/package.json +40 -0
  186. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/arraybuffer.slice/test/slice-buffer.js +227 -0
  187. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/.npmignore +1 -0
  188. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/.travis.yml +6 -0
  189. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/LICENSE-MIT +22 -0
  190. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/README.md +23 -0
  191. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/grunt.js +39 -0
  192. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/lib/base64-arraybuffer.js +59 -0
  193. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/package.json +56 -0
  194. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/base64-arraybuffer/test/base64-arraybuffer_test.js +72 -0
  195. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/.npmignore +2 -0
  196. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/.zuul.yml +8 -0
  197. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/Makefile +14 -0
  198. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/README.md +11 -0
  199. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/index.js +49 -0
  200. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/package.json +44 -0
  201. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/blob/test/index.js +52 -0
  202. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/.npmignore +15 -0
  203. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/History.md +5 -0
  204. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/LICENSE +20 -0
  205. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/Makefile +3 -0
  206. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/README.md +4 -0
  207. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/fixtures/big.json +1 -0
  208. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/index.js +58 -0
  209. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/README.md +54 -0
  210. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/build/build.js +209 -0
  211. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/component.json +19 -0
  212. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/index.js +3 -0
  213. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/package.json +53 -0
  214. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/package.json +39 -0
  215. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/has-binary/test.js +108 -0
  216. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/.gitattributes +2 -0
  217. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/.npmignore +20 -0
  218. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/.travis.yml +19 -0
  219. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/Gruntfile.js +72 -0
  220. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/LICENSE-GPL.txt +278 -0
  221. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/LICENSE-MIT.txt +20 -0
  222. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/README.md +119 -0
  223. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/bower.json +14 -0
  224. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/component.json +16 -0
  225. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/package.json +73 -0
  226. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/tests/generate-test-data.py +47 -0
  227. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/tests/index.html +35 -0
  228. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/tests/tests.js +242 -0
  229. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/utf8.js +239 -0
  230. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/node_modules/utf8/x.js +46 -0
  231. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/engine.io-parser/package.json +58 -0
  232. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/.npmignore +11 -0
  233. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/.travis.yml +5 -0
  234. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/History.md +322 -0
  235. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/Makefile +40 -0
  236. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/README.md +183 -0
  237. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/binding.gyp +16 -0
  238. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Makefile +355 -0
  239. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/.deps/Release/bufferutil.node.d +1 -0
  240. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/.deps/Release/obj.target/bufferutil/src/bufferutil.o.d +25 -0
  241. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/.deps/Release/obj.target/validation/src/validation.o.d +25 -0
  242. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/.deps/Release/validation.node.d +1 -0
  243. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/bufferutil.node +0 -0
  244. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/linker.lock +0 -0
  245. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/Release/validation.node +0 -0
  246. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/binding.Makefile +6 -0
  247. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/bufferutil.target.mk +156 -0
  248. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/config.gypi +117 -0
  249. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/gyp-mac-tool +512 -0
  250. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/build/validation.target.mk +156 -0
  251. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/builderror.log +15 -0
  252. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/index.js +49 -0
  253. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/BufferPool.js +59 -0
  254. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/BufferUtil.fallback.js +47 -0
  255. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/BufferUtil.js +16 -0
  256. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/ErrorCodes.js +24 -0
  257. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Receiver.hixie.js +180 -0
  258. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Receiver.js +585 -0
  259. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Sender.hixie.js +120 -0
  260. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Sender.js +229 -0
  261. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Validation.fallback.js +12 -0
  262. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/Validation.js +16 -0
  263. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/WebSocket.js +879 -0
  264. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/WebSocketServer.js +467 -0
  265. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/lib/browser.js +43 -0
  266. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/.dntrc +37 -0
  267. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/CHANGELOG.md +216 -0
  268. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/LICENSE.md +13 -0
  269. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/README.md +1208 -0
  270. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/appveyor.yml +32 -0
  271. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/include_dirs.js +1 -0
  272. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/nan.h +2428 -0
  273. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/nan/package.json +84 -0
  274. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/options/.npmignore +7 -0
  275. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/options/Makefile +12 -0
  276. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/options/README.md +69 -0
  277. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/options/lib/options.js +86 -0
  278. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/options/package.json +51 -0
  279. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/.npmignore +3 -0
  280. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/.travis.yml +17 -0
  281. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/README.md +97 -0
  282. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/index.js +125 -0
  283. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/package.json +68 -0
  284. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/node_modules/ultron/test.js +327 -0
  285. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/package.json +78 -0
  286. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/src/bufferutil.cc +117 -0
  287. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/src/validation.cc +145 -0
  288. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/wscat/README.md +26 -0
  289. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/wscat/bin/wscat +222 -0
  290. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/node_modules/ws/wscat/package.json +28 -0
  291. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/engine.io/package.json +74 -0
  292. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/.npmignore +15 -0
  293. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/LICENSE +20 -0
  294. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/Makefile +3 -0
  295. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/README.md +4 -0
  296. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/fixtures/big.json +1 -0
  297. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/gen.js +17 -0
  298. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/index.js +57 -0
  299. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/node_modules/isarray/README.md +54 -0
  300. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/node_modules/isarray/build/build.js +209 -0
  301. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/node_modules/isarray/component.json +19 -0
  302. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/node_modules/isarray/index.js +3 -0
  303. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/node_modules/isarray/package.json +53 -0
  304. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/package.json +37 -0
  305. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/has-binary-data/test.js +108 -0
  306. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/.npmignore +1 -0
  307. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/History.md +25 -0
  308. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/Readme.md +16 -0
  309. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/index.js +144 -0
  310. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/.jshintrc +3 -0
  311. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/.npmignore +6 -0
  312. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/History.md +126 -0
  313. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/Makefile +33 -0
  314. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/Readme.md +153 -0
  315. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/browser.js +144 -0
  316. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/component.json +19 -0
  317. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/debug.js +197 -0
  318. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/node.js +129 -0
  319. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/node_modules/ms/.npmignore +5 -0
  320. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/node_modules/ms/README.md +33 -0
  321. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/node_modules/ms/index.js +111 -0
  322. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/node_modules/ms/package.json +46 -0
  323. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/debug/package.json +69 -0
  324. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/.jscs.json +55 -0
  325. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/.npmignore +2 -0
  326. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/.travis.yml +18 -0
  327. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/CHANGELOG.md +151 -0
  328. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/LICENSE +21 -0
  329. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/README.md +76 -0
  330. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/index.js +70 -0
  331. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/isArguments.js +18 -0
  332. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/object-keys/package.json +82 -0
  333. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/.npmignore +5 -0
  334. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/.travis.yml +11 -0
  335. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/.zuul.yml +16 -0
  336. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/History.md +87 -0
  337. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/Makefile +11 -0
  338. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/Readme.md +73 -0
  339. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/bench/bench.js +10 -0
  340. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/bench/index.js +81 -0
  341. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/binary.js +141 -0
  342. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/index.js +396 -0
  343. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/is-buffer.js +13 -0
  344. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/LICENSE.txt +22 -0
  345. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/README.md +131 -0
  346. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/benchmark.js +3918 -0
  347. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/package.json +62 -0
  348. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/test/run-test.sh +9 -0
  349. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/benchmark/test/test.js +2074 -0
  350. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/.npmignore +2 -0
  351. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/.travis.yml +4 -0
  352. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/History.md +52 -0
  353. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/Makefile +7 -0
  354. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/Readme.md +74 -0
  355. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/bower.json +21 -0
  356. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/component.json +14 -0
  357. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/index.js +164 -0
  358. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/component-emitter/package.json +47 -0
  359. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/debug/Readme.md +115 -0
  360. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/debug/debug.js +137 -0
  361. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/debug/index.js +5 -0
  362. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/debug/lib/debug.js +147 -0
  363. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/debug/package.json +64 -0
  364. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/isarray/README.md +54 -0
  365. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/isarray/build/build.js +209 -0
  366. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/isarray/component.json +19 -0
  367. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/isarray/index.js +3 -0
  368. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/isarray/package.json +53 -0
  369. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/.gitmodules +6 -0
  370. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/.jamignore +10 -0
  371. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/.npmignore +11 -0
  372. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/.travis.yml +33 -0
  373. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/LICENSE +20 -0
  374. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/README.md +126 -0
  375. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/lib/json3.js +861 -0
  376. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/lib/json3.min.js +18 -0
  377. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/node_modules/json3/package.json +102 -0
  378. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/node_modules/socket.io-parser/package.json +51 -0
  379. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-adapter/package.json +41 -0
  380. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/History.md +386 -0
  381. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/LICENSE +22 -0
  382. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/README.md +173 -0
  383. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/index.js +2 -0
  384. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/lib/index.js +87 -0
  385. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/lib/manager.js +503 -0
  386. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/lib/on.js +24 -0
  387. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/lib/socket.js +385 -0
  388. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/lib/url.js +73 -0
  389. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/.npmignore +1 -0
  390. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/History.md +12 -0
  391. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/Makefile +8 -0
  392. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/Readme.md +34 -0
  393. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/component.json +11 -0
  394. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/index.js +85 -0
  395. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/package.json +45 -0
  396. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/backo2/test/index.js +18 -0
  397. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/.npmignore +4 -0
  398. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/History.md +13 -0
  399. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/Makefile +7 -0
  400. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/Readme.md +64 -0
  401. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/component.json +13 -0
  402. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/index.js +23 -0
  403. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-bind/package.json +47 -0
  404. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/.npmignore +2 -0
  405. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/.travis.yml +4 -0
  406. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/History.md +52 -0
  407. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/Makefile +7 -0
  408. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/Readme.md +74 -0
  409. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/bower.json +21 -0
  410. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/component.json +14 -0
  411. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/index.js +164 -0
  412. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/component-emitter/package.json +47 -0
  413. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/debug/Readme.md +115 -0
  414. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/debug/debug.js +137 -0
  415. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/debug/index.js +5 -0
  416. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/debug/lib/debug.js +147 -0
  417. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/debug/package.json +64 -0
  418. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/.npmignore +2 -0
  419. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/.travis.yml +41 -0
  420. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/.zuul.yml +20 -0
  421. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/History.md +468 -0
  422. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/Makefile +37 -0
  423. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/README.md +265 -0
  424. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/engine.io.js +4040 -0
  425. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/index.js +2 -0
  426. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/index.js +10 -0
  427. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/socket.js +705 -0
  428. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transport.js +159 -0
  429. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transports/index.js +53 -0
  430. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transports/polling-jsonp.js +233 -0
  431. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transports/polling-xhr.js +384 -0
  432. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transports/polling.js +245 -0
  433. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/transports/websocket.js +238 -0
  434. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/lib/xmlhttprequest.js +36 -0
  435. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/.bin/wscat +190 -0
  436. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/.npmignore +3 -0
  437. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/History.md +5 -0
  438. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/Makefile +16 -0
  439. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/Readme.md +24 -0
  440. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/component.json +10 -0
  441. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/index.js +7 -0
  442. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/package.json +44 -0
  443. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/component-inherit/test/inherit.js +21 -0
  444. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/.jshintrc +3 -0
  445. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/.npmignore +6 -0
  446. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/History.md +144 -0
  447. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/Makefile +33 -0
  448. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/Readme.md +156 -0
  449. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/browser.js +147 -0
  450. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/component.json +19 -0
  451. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/debug.js +197 -0
  452. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/node.js +129 -0
  453. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/node_modules/ms/.npmignore +5 -0
  454. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/node_modules/ms/README.md +33 -0
  455. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/node_modules/ms/index.js +111 -0
  456. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/node_modules/ms/package.json +46 -0
  457. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/debug/package.json +71 -0
  458. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/.npmignore +17 -0
  459. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/.travis.yml +45 -0
  460. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/.zuul.yml +18 -0
  461. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/History.md +100 -0
  462. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/LICENSE +22 -0
  463. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/Makefile +26 -0
  464. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/Readme.md +202 -0
  465. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/index.js +2 -0
  466. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/lib/browser.js +594 -0
  467. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/lib/index.js +467 -0
  468. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/lib/keys.js +19 -0
  469. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/.npmignore +2 -0
  470. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/.travis.yml +5 -0
  471. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/LICENCE +19 -0
  472. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/README.md +75 -0
  473. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/index.js +28 -0
  474. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/package.json +62 -0
  475. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/after/test/after-test.js +120 -0
  476. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/.npmignore +17 -0
  477. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/Makefile +8 -0
  478. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/README.md +17 -0
  479. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/index.js +29 -0
  480. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/package.json +40 -0
  481. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/arraybuffer.slice/test/slice-buffer.js +227 -0
  482. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/.npmignore +1 -0
  483. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/.travis.yml +6 -0
  484. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/LICENSE-MIT +22 -0
  485. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/README.md +23 -0
  486. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/grunt.js +39 -0
  487. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/lib/base64-arraybuffer.js +59 -0
  488. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/package.json +56 -0
  489. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/base64-arraybuffer/test/base64-arraybuffer_test.js +72 -0
  490. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/.npmignore +2 -0
  491. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/.zuul.yml +8 -0
  492. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/Makefile +14 -0
  493. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/README.md +11 -0
  494. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/index.js +49 -0
  495. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/package.json +44 -0
  496. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/blob/test/index.js +52 -0
  497. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/.npmignore +15 -0
  498. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/History.md +5 -0
  499. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/LICENSE +20 -0
  500. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/Makefile +3 -0
  501. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/README.md +4 -0
  502. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/fixtures/big.json +1 -0
  503. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/index.js +58 -0
  504. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/README.md +54 -0
  505. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/build/build.js +209 -0
  506. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/component.json +19 -0
  507. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/index.js +3 -0
  508. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/node_modules/isarray/package.json +53 -0
  509. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/package.json +39 -0
  510. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/has-binary/test.js +108 -0
  511. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/.gitattributes +2 -0
  512. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/.npmignore +20 -0
  513. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/.travis.yml +19 -0
  514. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/Gruntfile.js +72 -0
  515. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/LICENSE-GPL.txt +278 -0
  516. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/LICENSE-MIT.txt +20 -0
  517. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/README.md +119 -0
  518. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/bower.json +14 -0
  519. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/component.json +16 -0
  520. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/package.json +73 -0
  521. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/tests/generate-test-data.py +47 -0
  522. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/tests/index.html +35 -0
  523. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/tests/tests.js +242 -0
  524. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/utf8.js +239 -0
  525. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/node_modules/utf8/x.js +46 -0
  526. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/engine.io-parser/package.json +58 -0
  527. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/.npmignore +2 -0
  528. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/History.md +16 -0
  529. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/Makefile +11 -0
  530. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/Readme.md +24 -0
  531. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/component.json +16 -0
  532. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/index.js +23 -0
  533. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/.gitignore +3 -0
  534. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/History.md +15 -0
  535. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/Makefile +11 -0
  536. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/Readme.md +20 -0
  537. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/component.json +15 -0
  538. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/index.js +8 -0
  539. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/package.json +40 -0
  540. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/test/index.html +17 -0
  541. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/test/mocha.css +199 -0
  542. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/test/mocha.js +4699 -0
  543. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/node_modules/global/test/test.js +22 -0
  544. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/has-cors/package.json +57 -0
  545. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/Makefile +3 -0
  546. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/index.js +32 -0
  547. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/.npmignore +4 -0
  548. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/History.md +15 -0
  549. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/Makefile +5 -0
  550. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/Readme.md +61 -0
  551. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/example.js +10 -0
  552. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/index.js +38 -0
  553. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/.npmignore +4 -0
  554. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/History.md +10 -0
  555. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/Makefile +6 -0
  556. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/Readme.md +44 -0
  557. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/index.js +10 -0
  558. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/node_modules/callsite/package.json +45 -0
  559. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/node_modules/better-assert/package.json +65 -0
  560. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/package.json +37 -0
  561. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parsejson/test.js +21 -0
  562. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/Makefile +3 -0
  563. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/index.js +37 -0
  564. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/.npmignore +4 -0
  565. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/History.md +15 -0
  566. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/Makefile +5 -0
  567. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/Readme.md +61 -0
  568. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/example.js +10 -0
  569. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/index.js +38 -0
  570. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/.npmignore +4 -0
  571. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/History.md +10 -0
  572. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/Makefile +6 -0
  573. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/Readme.md +44 -0
  574. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/index.js +10 -0
  575. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/node_modules/callsite/package.json +45 -0
  576. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/node_modules/better-assert/package.json +65 -0
  577. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/package.json +37 -0
  578. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseqs/test.js +27 -0
  579. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/History.md +5 -0
  580. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/Makefile +3 -0
  581. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/index.js +39 -0
  582. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/.npmignore +4 -0
  583. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/History.md +15 -0
  584. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/Makefile +5 -0
  585. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/Readme.md +61 -0
  586. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/example.js +10 -0
  587. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/index.js +38 -0
  588. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/.npmignore +4 -0
  589. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/History.md +10 -0
  590. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/Makefile +6 -0
  591. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/Readme.md +44 -0
  592. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/index.js +10 -0
  593. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/package.json +45 -0
  594. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/node_modules/better-assert/package.json +65 -0
  595. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/package.json +45 -0
  596. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/parseuri/test.js +51 -0
  597. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/.npmignore +6 -0
  598. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/.travis.yml +6 -0
  599. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/History.md +312 -0
  600. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/Makefile +40 -0
  601. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/README.md +171 -0
  602. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/bench/parser.benchmark.js +115 -0
  603. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/bench/sender.benchmark.js +66 -0
  604. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/bench/speed.js +105 -0
  605. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/bench/util.js +105 -0
  606. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/bin/wscat +190 -0
  607. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/binding.gyp +16 -0
  608. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Makefile +355 -0
  609. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/.deps/Release/bufferutil.node.d +1 -0
  610. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/.deps/Release/obj.target/bufferutil/src/bufferutil.o.d +23 -0
  611. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/.deps/Release/obj.target/validation/src/validation.o.d +23 -0
  612. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/.deps/Release/validation.node.d +1 -0
  613. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/bufferutil.node +0 -0
  614. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/linker.lock +0 -0
  615. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/Release/validation.node +0 -0
  616. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/binding.Makefile +6 -0
  617. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/bufferutil.target.mk +156 -0
  618. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/config.gypi +117 -0
  619. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/gyp-mac-tool +512 -0
  620. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/build/validation.target.mk +156 -0
  621. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/builderror.log +1 -0
  622. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/.npmignore +1 -0
  623. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/package.json +18 -0
  624. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/public/app.js +39 -0
  625. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/public/index.html +22 -0
  626. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/public/uploader.js +55 -0
  627. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/fileapi/server.js +103 -0
  628. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats-express_3/package.json +17 -0
  629. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats-express_3/public/index.html +33 -0
  630. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats-express_3/server.js +21 -0
  631. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats/package.json +17 -0
  632. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats/public/index.html +33 -0
  633. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/serverstats/server.js +19 -0
  634. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/examples/ssl.js +59 -0
  635. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/index.js +26 -0
  636. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/BufferPool.js +59 -0
  637. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/BufferUtil.fallback.js +47 -0
  638. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/BufferUtil.js +16 -0
  639. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/ErrorCodes.js +24 -0
  640. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Receiver.hixie.js +180 -0
  641. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Receiver.js +591 -0
  642. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Sender.hixie.js +123 -0
  643. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Sender.js +227 -0
  644. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Validation.fallback.js +12 -0
  645. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/Validation.js +16 -0
  646. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/WebSocket.js +818 -0
  647. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/WebSocketServer.js +460 -0
  648. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/lib/browser.js +43 -0
  649. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/.npmignore +4 -0
  650. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/.travis.yml +4 -0
  651. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/History.md +107 -0
  652. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/Makefile +7 -0
  653. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/Readme.md +262 -0
  654. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/index.js +2 -0
  655. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/lib/commander.js +1026 -0
  656. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/commander/package.json +60 -0
  657. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/nan/.index.js +1 -0
  658. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/nan/LICENSE +43 -0
  659. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/nan/README.md +705 -0
  660. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/nan/nan.h +884 -0
  661. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/nan/package.json +53 -0
  662. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/options/.npmignore +7 -0
  663. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/options/Makefile +12 -0
  664. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/options/README.md +69 -0
  665. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/options/lib/options.js +86 -0
  666. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/options/package.json +51 -0
  667. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/tinycolor/.gitignore +5 -0
  668. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/tinycolor/README.md +3 -0
  669. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/tinycolor/example.js +3 -0
  670. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/tinycolor/package.json +48 -0
  671. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/node_modules/tinycolor/tinycolor.js +31 -0
  672. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/package.json +82 -0
  673. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/src/bufferutil.cc +117 -0
  674. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/src/validation.cc +145 -0
  675. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/BufferPool.test.js +63 -0
  676. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/Receiver.hixie.test.js +158 -0
  677. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/Receiver.test.js +255 -0
  678. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/Sender.hixie.test.js +134 -0
  679. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/Sender.test.js +24 -0
  680. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/Validation.test.js +23 -0
  681. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/WebSocket.integration.js +44 -0
  682. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/WebSocket.test.js +1724 -0
  683. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/WebSocketServer.test.js +1103 -0
  684. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/autobahn-server.js +29 -0
  685. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/autobahn.js +52 -0
  686. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/agent1-cert.pem +16 -0
  687. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/agent1-key.pem +15 -0
  688. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/ca1-cert.pem +15 -0
  689. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/ca1-key.pem +17 -0
  690. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/certificate.pem +13 -0
  691. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/key.pem +15 -0
  692. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/request.pem +11 -0
  693. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/fixtures/textfile +9 -0
  694. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/hybi-common.js +99 -0
  695. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/ws/test/testserver.js +180 -0
  696. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/LICENSE +22 -0
  697. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/README.md +57 -0
  698. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/autotest.watchr +8 -0
  699. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/example/demo.js +16 -0
  700. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/lib/XMLHttpRequest.js +642 -0
  701. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/package.json +42 -0
  702. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-constants.js +13 -0
  703. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-events.js +50 -0
  704. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-exceptions.js +62 -0
  705. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-headers.js +76 -0
  706. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-redirect-302.js +41 -0
  707. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-redirect-303.js +41 -0
  708. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-redirect-307.js +43 -0
  709. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-request-methods.js +62 -0
  710. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/test-request-protocols.js +34 -0
  711. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/node_modules/xmlhttprequest/tests/testdata.txt +1 -0
  712. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/engine.io-client/package.json +84 -0
  713. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/.npmignore +15 -0
  714. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/History.md +11 -0
  715. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/LICENSE +20 -0
  716. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/Makefile +3 -0
  717. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/README.md +4 -0
  718. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/fixtures/big.json +1 -0
  719. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/index.js +58 -0
  720. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/node_modules/isarray/README.md +54 -0
  721. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/node_modules/isarray/build/build.js +209 -0
  722. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/node_modules/isarray/component.json +19 -0
  723. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/node_modules/isarray/index.js +3 -0
  724. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/node_modules/isarray/package.json +53 -0
  725. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/package.json +39 -0
  726. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/has-binary/test.js +108 -0
  727. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/.npmignore +2 -0
  728. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/Makefile +11 -0
  729. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/Readme.md +15 -0
  730. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/component.json +10 -0
  731. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/index.js +10 -0
  732. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/indexof/package.json +32 -0
  733. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/.npmignore +3 -0
  734. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/History.md +10 -0
  735. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/Makefile +16 -0
  736. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/Readme.md +31 -0
  737. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/component.json +10 -0
  738. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/index.js +84 -0
  739. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/package.json +35 -0
  740. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/object-component/test/object.js +48 -0
  741. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/History.md +5 -0
  742. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/Makefile +3 -0
  743. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/index.js +25 -0
  744. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/.npmignore +4 -0
  745. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/History.md +15 -0
  746. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/Makefile +5 -0
  747. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/Readme.md +61 -0
  748. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/example.js +10 -0
  749. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/index.js +38 -0
  750. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/.npmignore +4 -0
  751. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/History.md +10 -0
  752. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/Makefile +6 -0
  753. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/Readme.md +44 -0
  754. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/index.js +10 -0
  755. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/node_modules/callsite/package.json +45 -0
  756. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/node_modules/better-assert/package.json +65 -0
  757. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/package.json +37 -0
  758. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/parseuri/test.js +42 -0
  759. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/to-array/.npmignore +3 -0
  760. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/to-array/LICENCE +19 -0
  761. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/to-array/README.md +22 -0
  762. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/to-array/index.js +13 -0
  763. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/node_modules/to-array/package.json +59 -0
  764. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/package.json +90 -0
  765. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-client/socket.io.js +7000 -0
  766. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/.npmignore +5 -0
  767. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/.travis.yml +11 -0
  768. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/.zuul.yml +16 -0
  769. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/History.md +97 -0
  770. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/Makefile +11 -0
  771. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/Readme.md +73 -0
  772. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/bench/bench.js +10 -0
  773. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/bench/index.js +81 -0
  774. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/bg.gif +0 -0
  775. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/binary.js +141 -0
  776. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/index.js +400 -0
  777. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/is-buffer.js +13 -0
  778. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/LICENSE.txt +22 -0
  779. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/README.md +131 -0
  780. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/benchmark.js +3918 -0
  781. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/package.json +62 -0
  782. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/test/run-test.sh +9 -0
  783. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/benchmark/test/test.js +2074 -0
  784. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/.npmignore +2 -0
  785. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/.travis.yml +4 -0
  786. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/History.md +52 -0
  787. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/Makefile +7 -0
  788. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/Readme.md +74 -0
  789. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/bower.json +21 -0
  790. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/component.json +14 -0
  791. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/index.js +164 -0
  792. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/component-emitter/package.json +47 -0
  793. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/debug/Readme.md +115 -0
  794. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/debug/debug.js +137 -0
  795. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/debug/index.js +5 -0
  796. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/debug/lib/debug.js +147 -0
  797. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/debug/package.json +64 -0
  798. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/isarray/README.md +54 -0
  799. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/isarray/build/build.js +209 -0
  800. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/isarray/component.json +19 -0
  801. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/isarray/index.js +3 -0
  802. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/isarray/package.json +53 -0
  803. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/.gitmodules +6 -0
  804. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/.jamignore +10 -0
  805. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/.npmignore +11 -0
  806. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/.travis.yml +33 -0
  807. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/LICENSE +20 -0
  808. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/README.md +126 -0
  809. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/lib/json3.js +861 -0
  810. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/lib/json3.min.js +18 -0
  811. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/node_modules/json3/package.json +102 -0
  812. data/spec/iface/driver/assets/node_modules/socket.io/node_modules/socket.io-parser/package.json +51 -0
  813. data/spec/iface/driver/assets/node_modules/socket.io/package.json +80 -0
  814. data/spec/iface/driver/assets/sockio_server.js +38 -0
  815. data/spec/iface/driver/controller_spec.rb +107 -0
  816. data/spec/iface/driver/debug_socketio_spec.rb +76 -0
  817. data/spec/iface/driver/debug_spec.rb +27 -0
  818. data/spec/iface/driver/net_spec.rb +80 -0
  819. data/spec/iface/driver/ping_spec.rb +53 -0
  820. data/spec/iface/driver/pipe_spec.rb +31 -0
  821. data/spec/iface/driver/sockio_spec.rb +52 -0
  822. data/spec/iface/driver/timer_spec.rb +39 -0
  823. data/spec/iface/driver/ui_spec.rb +157 -0
  824. data/spec/iface/kern/debug_spec.rb +40 -0
  825. data/spec/iface/kern/event_spec.rb +46 -0
  826. data/spec/iface/kern/net_spec.rb +27 -0
  827. data/spec/iface/kern/ping_spec.rb +123 -0
  828. data/spec/iface/kern/pipe_spec.rb +30 -0
  829. data/spec/kern/assets/controller0.rb +14 -0
  830. data/spec/kern/assets/controller1.rb +29 -0
  831. data/spec/kern/assets/controller_bare.rb +8 -0
  832. data/spec/kern/assets/controller_context.rb +9 -0
  833. data/spec/kern/assets/controller_def.rb +22 -0
  834. data/spec/kern/assets/controller_spots.rb +9 -0
  835. data/spec/kern/assets/controller_spots_embed.rb +19 -0
  836. data/spec/kern/assets/controller_spots_embed_removed.rb +28 -0
  837. data/spec/kern/assets/embed_info.rb +29 -0
  838. data/spec/kern/assets/event_gw.rb +21 -0
  839. data/spec/kern/assets/goto.rb +29 -0
  840. data/spec/kern/assets/goto2.rb +19 -0
  841. data/spec/kern/assets/lower_event.rb +30 -0
  842. data/spec/kern/assets/raise_event.rb +30 -0
  843. data/spec/kern/assets/rest_service.rb +21 -0
  844. data/spec/kern/assets/send_event.rb +14 -0
  845. data/spec/kern/assets/test_event.rb +14 -0
  846. data/spec/kern/assets/test_event2.rb +26 -0
  847. data/spec/kern/assets/test_event3.rb +21 -0
  848. data/spec/kern/assets/timer_service.rb +20 -0
  849. data/spec/kern/controller_spec.rb +500 -0
  850. data/spec/kern/debug_spec.rb +38 -0
  851. data/spec/kern/debug_ui_spec.rb +243 -0
  852. data/spec/kern/net_spec.rb +14 -0
  853. data/spec/kern/rest_service_spec.rb +45 -0
  854. data/spec/kern/timer_service_spec.rb +40 -0
  855. data/spec/lib/helpers.rb +318 -0
  856. data/spec/lib/io_extensions.rb +13 -0
  857. data/spec/lib/rspec_extensions.rb +219 -0
  858. data/spec/lib/temp_dir.rb +57 -0
  859. metadata +1664 -14
  860. data/app/drivers/iface/ui.js +0 -31
  861. data/app/kern/hello.js +0 -1
  862. data/docs/driver_interface.md +0 -61
  863. data/docs/interface.md +0 -5
  864. data/docs/platform_drivers.md +0 -36
  865. data/spec/build_valid_spec.rb +0 -61
  866. data/spec/drivers/net_spec.rb +0 -159
  867. data/spec/helpers.rb +0 -140
@@ -0,0 +1,123 @@
1
+ /*!
2
+ * ws: a node.js websocket client
3
+ * Copyright(c) 2011 Einar Otto Stangvik <einaros@gmail.com>
4
+ * MIT Licensed
5
+ */
6
+
7
+ var events = require('events')
8
+ , util = require('util')
9
+ , EventEmitter = events.EventEmitter;
10
+
11
+ /**
12
+ * Hixie Sender implementation
13
+ */
14
+
15
+ function Sender(socket) {
16
+ this.socket = socket;
17
+ this.continuationFrame = false;
18
+ this.isClosed = false;
19
+ }
20
+
21
+ module.exports = Sender;
22
+
23
+ /**
24
+ * Inherits from EventEmitter.
25
+ */
26
+
27
+ util.inherits(Sender, events.EventEmitter);
28
+
29
+ /**
30
+ * Frames and writes data.
31
+ *
32
+ * @api public
33
+ */
34
+
35
+ Sender.prototype.send = function(data, options, cb) {
36
+ if (this.isClosed) return;
37
+ /*
38
+ if (options && options.binary) {
39
+ this.error('hixie websockets do not support binary');
40
+ return;
41
+ }
42
+ */
43
+ var isString = typeof data == 'string'
44
+ , length = isString ? Buffer.byteLength(data) : data.length
45
+ , lengthbytes = (length > 127) ? 2 : 1 // assume less than 2**14 bytes
46
+ , writeStartMarker = this.continuationFrame == false
47
+ , writeEndMarker = !options || !(typeof options.fin != 'undefined' && !options.fin)
48
+ , buffer = new Buffer((writeStartMarker ? ((options && options.binary) ? (1 + lengthbytes) : 1) : 0) + length + ((writeEndMarker && !(options && options.binary)) ? 1 : 0))
49
+ , offset = writeStartMarker ? 1 : 0;
50
+
51
+ if (writeStartMarker) {
52
+ if (options && options.binary) {
53
+ buffer.write('\x80', 'binary');
54
+ // assume length less than 2**14 bytes
55
+ if (lengthbytes > 1)
56
+ buffer.write(String.fromCharCode(128+length/128), offset++, 'binary');
57
+ buffer.write(String.fromCharCode(length&0x7f), offset++, 'binary');
58
+ } else
59
+ buffer.write('\x00', 'binary');
60
+ }
61
+
62
+ if (isString) buffer.write(data, offset, 'utf8');
63
+ else data.copy(buffer, offset, 0);
64
+
65
+ if (writeEndMarker) {
66
+ if (options && options.binary) {
67
+ // sending binary, not writing end marker
68
+ } else
69
+ buffer.write('\xff', offset + length, 'binary');
70
+ this.continuationFrame = false;
71
+ }
72
+ else this.continuationFrame = true;
73
+
74
+ try {
75
+ this.socket.write(buffer, 'binary', cb);
76
+ } catch (e) {
77
+ this.error(e.toString());
78
+ }
79
+ }
80
+
81
+ /**
82
+ * Sends a close instruction to the remote party.
83
+ *
84
+ * @api public
85
+ */
86
+
87
+ Sender.prototype.close = function(code, data, mask, cb) {
88
+ if (this.isClosed) return;
89
+ this.isClosed = true;
90
+ try {
91
+ if (this.continuationFrame) this.socket.write(new Buffer([0xff], 'binary'));
92
+ this.socket.write(new Buffer([0xff, 0x00]), 'binary', cb);
93
+ } catch (e) {
94
+ this.error(e.toString());
95
+ }
96
+ }
97
+
98
+ /**
99
+ * Sends a ping message to the remote party. Not available for hixie.
100
+ *
101
+ * @api public
102
+ */
103
+
104
+ Sender.prototype.ping = function(data, options) {}
105
+
106
+ /**
107
+ * Sends a pong message to the remote party. Not available for hixie.
108
+ *
109
+ * @api public
110
+ */
111
+
112
+ Sender.prototype.pong = function(data, options) {}
113
+
114
+ /**
115
+ * Handles an error
116
+ *
117
+ * @api private
118
+ */
119
+
120
+ Sender.prototype.error = function (reason) {
121
+ this.emit('error', reason);
122
+ return this;
123
+ }
@@ -0,0 +1,227 @@
1
+ /*!
2
+ * ws: a node.js websocket client
3
+ * Copyright(c) 2011 Einar Otto Stangvik <einaros@gmail.com>
4
+ * MIT Licensed
5
+ */
6
+
7
+ var events = require('events')
8
+ , util = require('util')
9
+ , EventEmitter = events.EventEmitter
10
+ , ErrorCodes = require('./ErrorCodes')
11
+ , bufferUtil = require('./BufferUtil').BufferUtil;
12
+
13
+ /**
14
+ * HyBi Sender implementation
15
+ */
16
+
17
+ function Sender(socket) {
18
+ this._socket = socket;
19
+ this.firstFragment = true;
20
+ }
21
+
22
+ /**
23
+ * Inherits from EventEmitter.
24
+ */
25
+
26
+ util.inherits(Sender, events.EventEmitter);
27
+
28
+ /**
29
+ * Sends a close instruction to the remote party.
30
+ *
31
+ * @api public
32
+ */
33
+
34
+ Sender.prototype.close = function(code, data, mask) {
35
+ if (typeof code !== 'undefined') {
36
+ if (typeof code !== 'number' ||
37
+ !ErrorCodes.isValidErrorCode(code)) throw new Error('first argument must be a valid error code number');
38
+ }
39
+ code = code || 1000;
40
+ var dataBuffer = new Buffer(2 + (data ? Buffer.byteLength(data) : 0));
41
+ writeUInt16BE.call(dataBuffer, code, 0);
42
+ if (dataBuffer.length > 2) dataBuffer.write(data, 2);
43
+ this.frameAndSend(0x8, dataBuffer, true, mask);
44
+ }
45
+
46
+ /**
47
+ * Sends a ping message to the remote party.
48
+ *
49
+ * @api public
50
+ */
51
+
52
+ Sender.prototype.ping = function(data, options) {
53
+ var mask = options && options.mask;
54
+ this.frameAndSend(0x9, data || '', true, mask);
55
+ }
56
+
57
+ /**
58
+ * Sends a pong message to the remote party.
59
+ *
60
+ * @api public
61
+ */
62
+
63
+ Sender.prototype.pong = function(data, options) {
64
+ var mask = options && options.mask;
65
+ this.frameAndSend(0xa, data || '', true, mask);
66
+ }
67
+
68
+ /**
69
+ * Sends text or binary data to the remote party.
70
+ *
71
+ * @api public
72
+ */
73
+
74
+ Sender.prototype.send = function(data, options, cb) {
75
+ var finalFragment = options && options.fin === false ? false : true;
76
+ var mask = options && options.mask;
77
+ var opcode = options && options.binary ? 2 : 1;
78
+ if (this.firstFragment === false) opcode = 0;
79
+ else this.firstFragment = false;
80
+ if (finalFragment) this.firstFragment = true
81
+ this.frameAndSend(opcode, data, finalFragment, mask, cb);
82
+ }
83
+
84
+ /**
85
+ * Frames and sends a piece of data according to the HyBi WebSocket protocol.
86
+ *
87
+ * @api private
88
+ */
89
+
90
+ Sender.prototype.frameAndSend = function(opcode, data, finalFragment, maskData, cb) {
91
+ var canModifyData = false;
92
+
93
+ if (!data) {
94
+ try {
95
+ this._socket.write(new Buffer([opcode | (finalFragment ? 0x80 : 0), 0 | (maskData ? 0x80 : 0)].concat(maskData ? [0, 0, 0, 0] : [])), 'binary', cb);
96
+ }
97
+ catch (e) {
98
+ if (typeof cb == 'function') cb(e);
99
+ else this.emit('error', e);
100
+ }
101
+ return;
102
+ }
103
+
104
+ if (!Buffer.isBuffer(data)) {
105
+ canModifyData = true;
106
+ if (data && (typeof data.byteLength !== 'undefined' || typeof data.buffer !== 'undefined')) {
107
+ data = getArrayBuffer(data);
108
+ } else {
109
+ data = new Buffer(data);
110
+ }
111
+ }
112
+
113
+ var dataLength = data.length
114
+ , dataOffset = maskData ? 6 : 2
115
+ , secondByte = dataLength;
116
+
117
+ if (dataLength >= 65536) {
118
+ dataOffset += 8;
119
+ secondByte = 127;
120
+ }
121
+ else if (dataLength > 125) {
122
+ dataOffset += 2;
123
+ secondByte = 126;
124
+ }
125
+
126
+ var mergeBuffers = dataLength < 32768 || (maskData && !canModifyData);
127
+ var totalLength = mergeBuffers ? dataLength + dataOffset : dataOffset;
128
+ var outputBuffer = new Buffer(totalLength);
129
+ outputBuffer[0] = finalFragment ? opcode | 0x80 : opcode;
130
+
131
+ switch (secondByte) {
132
+ case 126:
133
+ writeUInt16BE.call(outputBuffer, dataLength, 2);
134
+ break;
135
+ case 127:
136
+ writeUInt32BE.call(outputBuffer, 0, 2);
137
+ writeUInt32BE.call(outputBuffer, dataLength, 6);
138
+ }
139
+
140
+ if (maskData) {
141
+ outputBuffer[1] = secondByte | 0x80;
142
+ var mask = this._randomMask || (this._randomMask = getRandomMask());
143
+ outputBuffer[dataOffset - 4] = mask[0];
144
+ outputBuffer[dataOffset - 3] = mask[1];
145
+ outputBuffer[dataOffset - 2] = mask[2];
146
+ outputBuffer[dataOffset - 1] = mask[3];
147
+ if (mergeBuffers) {
148
+ bufferUtil.mask(data, mask, outputBuffer, dataOffset, dataLength);
149
+ try {
150
+ this._socket.write(outputBuffer, 'binary', cb);
151
+ }
152
+ catch (e) {
153
+ if (typeof cb == 'function') cb(e);
154
+ else this.emit('error', e);
155
+ }
156
+ }
157
+ else {
158
+ bufferUtil.mask(data, mask, data, 0, dataLength);
159
+ try {
160
+ this._socket.write(outputBuffer, 'binary');
161
+ this._socket.write(data, 'binary', cb);
162
+ }
163
+ catch (e) {
164
+ if (typeof cb == 'function') cb(e);
165
+ else this.emit('error', e);
166
+ }
167
+ }
168
+ }
169
+ else {
170
+ outputBuffer[1] = secondByte;
171
+ if (mergeBuffers) {
172
+ data.copy(outputBuffer, dataOffset);
173
+ try {
174
+ this._socket.write(outputBuffer, 'binary', cb);
175
+ }
176
+ catch (e) {
177
+ if (typeof cb == 'function') cb(e);
178
+ else this.emit('error', e);
179
+ }
180
+ }
181
+ else {
182
+ try {
183
+ this._socket.write(outputBuffer, 'binary');
184
+ this._socket.write(data, 'binary', cb);
185
+ }
186
+ catch (e) {
187
+ if (typeof cb == 'function') cb(e);
188
+ else this.emit('error', e);
189
+ }
190
+ }
191
+ }
192
+ }
193
+
194
+ module.exports = Sender;
195
+
196
+ function writeUInt16BE(value, offset) {
197
+ this[offset] = (value & 0xff00)>>8;
198
+ this[offset+1] = value & 0xff;
199
+ }
200
+
201
+ function writeUInt32BE(value, offset) {
202
+ this[offset] = (value & 0xff000000)>>24;
203
+ this[offset+1] = (value & 0xff0000)>>16;
204
+ this[offset+2] = (value & 0xff00)>>8;
205
+ this[offset+3] = value & 0xff;
206
+ }
207
+
208
+ function getArrayBuffer(data) {
209
+ // data is either an ArrayBuffer or ArrayBufferView.
210
+ var array = new Uint8Array(data.buffer || data)
211
+ , l = data.byteLength || data.length
212
+ , o = data.byteOffset || 0
213
+ , buffer = new Buffer(l);
214
+ for (var i = 0; i < l; ++i) {
215
+ buffer[i] = array[o+i];
216
+ }
217
+ return buffer;
218
+ }
219
+
220
+ function getRandomMask() {
221
+ return new Buffer([
222
+ ~~(Math.random() * 255),
223
+ ~~(Math.random() * 255),
224
+ ~~(Math.random() * 255),
225
+ ~~(Math.random() * 255)
226
+ ]);
227
+ }
@@ -0,0 +1,12 @@
1
+ /*!
2
+ * ws: a node.js websocket client
3
+ * Copyright(c) 2011 Einar Otto Stangvik <einaros@gmail.com>
4
+ * MIT Licensed
5
+ */
6
+
7
+ module.exports.Validation = {
8
+ isValidUTF8: function(buffer) {
9
+ return true;
10
+ }
11
+ };
12
+
@@ -0,0 +1,16 @@
1
+ /*!
2
+ * ws: a node.js websocket client
3
+ * Copyright(c) 2011 Einar Otto Stangvik <einaros@gmail.com>
4
+ * MIT Licensed
5
+ */
6
+
7
+ try {
8
+ module.exports = require('../build/Release/validation');
9
+ } catch (e) { try {
10
+ module.exports = require('../build/default/validation');
11
+ } catch (e) { try {
12
+ module.exports = require('./Validation.fallback');
13
+ } catch (e) {
14
+ console.error('validation.node seems to not have been built. Run npm install.');
15
+ throw e;
16
+ }}}
@@ -0,0 +1,818 @@
1
+ /*!
2
+ * ws: a node.js websocket client
3
+ * Copyright(c) 2011 Einar Otto Stangvik <einaros@gmail.com>
4
+ * MIT Licensed
5
+ */
6
+
7
+ var util = require('util')
8
+ , events = require('events')
9
+ , http = require('http')
10
+ , https = require('https')
11
+ , crypto = require('crypto')
12
+ , url = require('url')
13
+ , fs = require('fs')
14
+ , Options = require('options')
15
+ , Sender = require('./Sender')
16
+ , Receiver = require('./Receiver')
17
+ , SenderHixie = require('./Sender.hixie')
18
+ , ReceiverHixie = require('./Receiver.hixie');
19
+
20
+ /**
21
+ * Constants
22
+ */
23
+
24
+ // Default protocol version
25
+
26
+ var protocolVersion = 13;
27
+
28
+ // Close timeout
29
+
30
+ var closeTimeout = 30000; // Allow 5 seconds to terminate the connection cleanly
31
+
32
+ /**
33
+ * Node version 0.4 and 0.6 compatibility
34
+ */
35
+
36
+ var isNodeV4 = /^v0\.4/.test(process.version);
37
+
38
+ /**
39
+ * WebSocket implementation
40
+ */
41
+
42
+ function WebSocket(address, protocols, options) {
43
+
44
+ if (protocols && !Array.isArray(protocols) && 'object' == typeof protocols) {
45
+ // accept the "options" Object as the 2nd argument
46
+ options = protocols;
47
+ protocols = null;
48
+ }
49
+ if ('string' == typeof protocols) {
50
+ protocols = [ protocols ];
51
+ }
52
+ if (!Array.isArray(protocols)) {
53
+ protocols = [];
54
+ }
55
+ // TODO: actually handle the `Sub-Protocols` part of the WebSocket client
56
+
57
+ this._socket = null;
58
+ this.bytesReceived = 0;
59
+ this.readyState = null;
60
+ this.supports = {};
61
+
62
+ if (Array.isArray(address)) {
63
+ initAsServerClient.apply(this, address.concat(options));
64
+ } else {
65
+ initAsClient.apply(this, [address, protocols, options]);
66
+ }
67
+ }
68
+
69
+ /**
70
+ * Inherits from EventEmitter.
71
+ */
72
+
73
+ util.inherits(WebSocket, events.EventEmitter);
74
+
75
+ /**
76
+ * Ready States
77
+ */
78
+
79
+ ["CONNECTING", "OPEN", "CLOSING", "CLOSED"].forEach(function (state, index) {
80
+ WebSocket.prototype[state] = WebSocket[state] = index;
81
+ });
82
+
83
+ /**
84
+ * Gracefully closes the connection, after sending a description message to the server
85
+ *
86
+ * @param {Object} data to be sent to the server
87
+ * @api public
88
+ */
89
+
90
+ WebSocket.prototype.close = function(code, data) {
91
+ if (this.readyState == WebSocket.CLOSING || this.readyState == WebSocket.CLOSED) return;
92
+ if (this.readyState == WebSocket.CONNECTING) {
93
+ this.readyState = WebSocket.CLOSED;
94
+ return;
95
+ }
96
+ try {
97
+ this.readyState = WebSocket.CLOSING;
98
+ this._closeCode = code;
99
+ this._closeMessage = data;
100
+ var mask = !this._isServer;
101
+ this._sender.close(code, data, mask);
102
+ }
103
+ catch (e) {
104
+ this.emit('error', e);
105
+ }
106
+ finally {
107
+ this.terminate();
108
+ }
109
+ }
110
+
111
+ /**
112
+ * Pause the client stream
113
+ *
114
+ * @api public
115
+ */
116
+
117
+ WebSocket.prototype.pause = function() {
118
+ if (this.readyState != WebSocket.OPEN) throw new Error('not opened');
119
+ return this._socket.pause();
120
+ }
121
+
122
+ /**
123
+ * Sends a ping
124
+ *
125
+ * @param {Object} data to be sent to the server
126
+ * @param {Object} Members - mask: boolean, binary: boolean
127
+ * @param {boolean} dontFailWhenClosed indicates whether or not to throw if the connection isnt open
128
+ * @api public
129
+ */
130
+
131
+ WebSocket.prototype.ping = function(data, options, dontFailWhenClosed) {
132
+ if (this.readyState != WebSocket.OPEN) {
133
+ if (dontFailWhenClosed === true) return;
134
+ throw new Error('not opened');
135
+ }
136
+ options = options || {};
137
+ if (typeof options.mask == 'undefined') options.mask = !this._isServer;
138
+ this._sender.ping(data, options);
139
+ }
140
+
141
+ /**
142
+ * Sends a pong
143
+ *
144
+ * @param {Object} data to be sent to the server
145
+ * @param {Object} Members - mask: boolean, binary: boolean
146
+ * @param {boolean} dontFailWhenClosed indicates whether or not to throw if the connection isnt open
147
+ * @api public
148
+ */
149
+
150
+ WebSocket.prototype.pong = function(data, options, dontFailWhenClosed) {
151
+ if (this.readyState != WebSocket.OPEN) {
152
+ if (dontFailWhenClosed === true) return;
153
+ throw new Error('not opened');
154
+ }
155
+ options = options || {};
156
+ if (typeof options.mask == 'undefined') options.mask = !this._isServer;
157
+ this._sender.pong(data, options);
158
+ }
159
+
160
+ /**
161
+ * Resume the client stream
162
+ *
163
+ * @api public
164
+ */
165
+
166
+ WebSocket.prototype.resume = function() {
167
+ if (this.readyState != WebSocket.OPEN) throw new Error('not opened');
168
+ return this._socket.resume();
169
+ }
170
+
171
+ /**
172
+ * Sends a piece of data
173
+ *
174
+ * @param {Object} data to be sent to the server
175
+ * @param {Object} Members - mask: boolean, binary: boolean
176
+ * @param {function} Optional callback which is executed after the send completes
177
+ * @api public
178
+ */
179
+
180
+ WebSocket.prototype.send = function(data, options, cb) {
181
+ if (typeof options == 'function') {
182
+ cb = options;
183
+ options = {};
184
+ }
185
+ if (this.readyState != WebSocket.OPEN) {
186
+ if (typeof cb == 'function') cb(new Error('not opened'));
187
+ else throw new Error('not opened');
188
+ return;
189
+ }
190
+ if (!data) data = '';
191
+ if (this._queue) {
192
+ var self = this;
193
+ this._queue.push(function() { self.send(data, options, cb); });
194
+ return;
195
+ }
196
+ options = options || {};
197
+ options.fin = true;
198
+ if (typeof options.binary == 'undefined') {
199
+ options.binary = (data instanceof ArrayBuffer || data instanceof Buffer ||
200
+ data instanceof Uint8Array ||
201
+ data instanceof Uint16Array ||
202
+ data instanceof Uint32Array ||
203
+ data instanceof Int8Array ||
204
+ data instanceof Int16Array ||
205
+ data instanceof Int32Array ||
206
+ data instanceof Float32Array ||
207
+ data instanceof Float64Array);
208
+ }
209
+ if (typeof options.mask == 'undefined') options.mask = !this._isServer;
210
+ if (data instanceof fs.ReadStream) {
211
+ startQueue(this);
212
+ var self = this;
213
+ sendStream(this, data, options, function(error) {
214
+ process.nextTick(function() { executeQueueSends(self); });
215
+ if (typeof cb == 'function') cb(error);
216
+ });
217
+ }
218
+ else this._sender.send(data, options, cb);
219
+ }
220
+
221
+ /**
222
+ * Streams data through calls to a user supplied function
223
+ *
224
+ * @param {Object} Members - mask: boolean, binary: boolean
225
+ * @param {function} 'function (error, send)' which is executed on successive ticks of which send is 'function (data, final)'.
226
+ * @api public
227
+ */
228
+
229
+ WebSocket.prototype.stream = function(options, cb) {
230
+ if (typeof options == 'function') {
231
+ cb = options;
232
+ options = {};
233
+ }
234
+ var self = this;
235
+ if (typeof cb != 'function') throw new Error('callback must be provided');
236
+ if (this.readyState != WebSocket.OPEN) {
237
+ if (typeof cb == 'function') cb(new Error('not opened'));
238
+ else throw new Error('not opened');
239
+ return;
240
+ }
241
+ if (this._queue) {
242
+ this._queue.push(function() { self.stream(options, cb); });
243
+ return;
244
+ }
245
+ options = options || {};
246
+ if (typeof options.mask == 'undefined') options.mask = !this._isServer;
247
+ startQueue(this);
248
+ var send = function(data, final) {
249
+ try {
250
+ if (self.readyState != WebSocket.OPEN) throw new Error('not opened');
251
+ options.fin = final === true;
252
+ self._sender.send(data, options);
253
+ if (!final) process.nextTick(cb.bind(null, null, send));
254
+ else executeQueueSends(self);
255
+ }
256
+ catch (e) {
257
+ if (typeof cb == 'function') cb(e);
258
+ else {
259
+ delete self._queue;
260
+ self.emit('error', e);
261
+ }
262
+ }
263
+ }
264
+ process.nextTick(cb.bind(null, null, send));
265
+ }
266
+
267
+ /**
268
+ * Immediately shuts down the connection
269
+ *
270
+ * @api public
271
+ */
272
+
273
+ WebSocket.prototype.terminate = function() {
274
+ if (this.readyState == WebSocket.CLOSED) return;
275
+ if (this._socket) {
276
+ try {
277
+ // End the connection
278
+ this._socket.end();
279
+ }
280
+ catch (e) {
281
+ // Socket error during end() call, so just destroy it right now
282
+ cleanupWebsocketResources.call(this, true);
283
+ return;
284
+ }
285
+
286
+ // Add a timeout to ensure that the connection is completely
287
+ // cleaned up within 30 seconds, even if the clean close procedure
288
+ // fails for whatever reason
289
+ this._closeTimer = setTimeout(cleanupWebsocketResources.bind(this, true), closeTimeout);
290
+ }
291
+ else if (this.readyState == WebSocket.CONNECTING) {
292
+ cleanupWebsocketResources.call(this, true);
293
+ }
294
+ };
295
+
296
+ /**
297
+ * Expose bufferedAmount
298
+ *
299
+ * @api public
300
+ */
301
+
302
+ Object.defineProperty(WebSocket.prototype, 'bufferedAmount', {
303
+ get: function get() {
304
+ var amount = 0;
305
+ if (this._socket) {
306
+ amount = this._socket.bufferSize || 0;
307
+ }
308
+ return amount;
309
+ }
310
+ });
311
+
312
+ /**
313
+ * Emulates the W3C Browser based WebSocket interface using function members.
314
+ *
315
+ * @see http://dev.w3.org/html5/websockets/#the-websocket-interface
316
+ * @api public
317
+ */
318
+
319
+ ['open', 'error', 'close', 'message'].forEach(function(method) {
320
+ Object.defineProperty(WebSocket.prototype, 'on' + method, {
321
+ /**
322
+ * Returns the current listener
323
+ *
324
+ * @returns {Mixed} the set function or undefined
325
+ * @api public
326
+ */
327
+
328
+ get: function get() {
329
+ var listener = this.listeners(method)[0];
330
+ return listener ? (listener._listener ? listener._listener : listener) : undefined;
331
+ },
332
+
333
+ /**
334
+ * Start listening for events
335
+ *
336
+ * @param {Function} listener the listener
337
+ * @returns {Mixed} the set function or undefined
338
+ * @api public
339
+ */
340
+
341
+ set: function set(listener) {
342
+ this.removeAllListeners(method);
343
+ this.addEventListener(method, listener);
344
+ }
345
+ });
346
+ });
347
+
348
+ /**
349
+ * Emulates the W3C Browser based WebSocket interface using addEventListener.
350
+ *
351
+ * @see https://developer.mozilla.org/en/DOM/element.addEventListener
352
+ * @see http://dev.w3.org/html5/websockets/#the-websocket-interface
353
+ * @api public
354
+ */
355
+ WebSocket.prototype.addEventListener = function(method, listener) {
356
+ var target = this;
357
+ if (typeof listener === 'function') {
358
+ if (method === 'message') {
359
+ function onMessage (data, flags) {
360
+ listener.call(this, new MessageEvent(data, flags.binary ? 'Binary' : 'Text', target));
361
+ }
362
+ // store a reference so we can return the original function from the addEventListener hook
363
+ onMessage._listener = listener;
364
+ this.on(method, onMessage);
365
+ } else if (method === 'close') {
366
+ function onClose (code, message) {
367
+ listener.call(this, new CloseEvent(code, message, target));
368
+ }
369
+ // store a reference so we can return the original function from the addEventListener hook
370
+ onClose._listener = listener;
371
+ this.on(method, onClose);
372
+ } else if (method === 'error') {
373
+ function onError (event) {
374
+ event.target = target;
375
+ listener.call(this, event);
376
+ }
377
+ // store a reference so we can return the original function from the addEventListener hook
378
+ onError._listener = listener;
379
+ this.on(method, onError);
380
+ } else if (method === 'open') {
381
+ function onOpen () {
382
+ listener.call(this, new OpenEvent(target));
383
+ }
384
+ // store a reference so we can return the original function from the addEventListener hook
385
+ onOpen._listener = listener;
386
+ this.on(method, onOpen);
387
+ } else {
388
+ this.on(method, listener);
389
+ }
390
+ }
391
+ }
392
+
393
+ module.exports = WebSocket;
394
+
395
+ /**
396
+ * W3C MessageEvent
397
+ *
398
+ * @see http://www.w3.org/TR/html5/comms.html
399
+ * @api private
400
+ */
401
+
402
+ function MessageEvent(dataArg, typeArg, target) {
403
+ this.data = dataArg;
404
+ this.type = typeArg;
405
+ this.target = target;
406
+ }
407
+
408
+ /**
409
+ * W3C CloseEvent
410
+ *
411
+ * @see http://www.w3.org/TR/html5/comms.html
412
+ * @api private
413
+ */
414
+
415
+ function CloseEvent(code, reason, target) {
416
+ this.wasClean = (typeof code == 'undefined' || code == 1000);
417
+ this.code = code;
418
+ this.reason = reason;
419
+ this.target = target;
420
+ }
421
+
422
+ /**
423
+ * W3C OpenEvent
424
+ *
425
+ * @see http://www.w3.org/TR/html5/comms.html
426
+ * @api private
427
+ */
428
+
429
+ function OpenEvent(target) {
430
+ this.target = target;
431
+ }
432
+
433
+ /**
434
+ * Entirely private apis,
435
+ * which may or may not be bound to a sepcific WebSocket instance.
436
+ */
437
+
438
+ function initAsServerClient(req, socket, upgradeHead, options) {
439
+ options = new Options({
440
+ protocolVersion: protocolVersion,
441
+ protocol: null
442
+ }).merge(options);
443
+
444
+ // expose state properties
445
+ this.protocol = options.value.protocol;
446
+ this.protocolVersion = options.value.protocolVersion;
447
+ this.supports.binary = (this.protocolVersion != 'hixie-76');
448
+ this.upgradeReq = req;
449
+ this.readyState = WebSocket.CONNECTING;
450
+ this._isServer = true;
451
+
452
+ // establish connection
453
+ if (options.value.protocolVersion == 'hixie-76') establishConnection.call(this, ReceiverHixie, SenderHixie, socket, upgradeHead);
454
+ else establishConnection.call(this, Receiver, Sender, socket, upgradeHead);
455
+ }
456
+
457
+ function initAsClient(address, protocols, options) {
458
+ options = new Options({
459
+ origin: null,
460
+ protocolVersion: protocolVersion,
461
+ host: null,
462
+ headers: null,
463
+ protocol: null,
464
+ agent: null,
465
+
466
+ // ssl-related options
467
+ pfx: null,
468
+ key: null,
469
+ passphrase: null,
470
+ cert: null,
471
+ ca: null,
472
+ ciphers: null,
473
+ rejectUnauthorized: null
474
+ }).merge(options);
475
+ if (options.value.protocolVersion != 8 && options.value.protocolVersion != 13) {
476
+ throw new Error('unsupported protocol version');
477
+ }
478
+
479
+ // verify url and establish http class
480
+ var serverUrl = url.parse(address);
481
+ var isUnixSocket = serverUrl.protocol === 'ws+unix:';
482
+ if (!serverUrl.host && !isUnixSocket) throw new Error('invalid url');
483
+ var isSecure = serverUrl.protocol === 'wss:' || serverUrl.protocol === 'https:';
484
+ var httpObj = isSecure ? https : http;
485
+ var port = serverUrl.port || (isSecure ? 443 : 80);
486
+ var auth = serverUrl.auth;
487
+
488
+ // expose state properties
489
+ this._isServer = false;
490
+ this.url = address;
491
+ this.protocolVersion = options.value.protocolVersion;
492
+ this.supports.binary = (this.protocolVersion != 'hixie-76');
493
+
494
+ // begin handshake
495
+ var key = new Buffer(options.value.protocolVersion + '-' + Date.now()).toString('base64');
496
+ var shasum = crypto.createHash('sha1');
497
+ shasum.update(key + '258EAFA5-E914-47DA-95CA-C5AB0DC85B11');
498
+ var expectedServerKey = shasum.digest('base64');
499
+
500
+ var agent = options.value.agent;
501
+ // node<=v0.4.x compatibility
502
+ if (!agent && isNodeV4) {
503
+ isNodeV4 = true;
504
+ agent = new httpObj.Agent({
505
+ host: serverUrl.hostname,
506
+ port: port
507
+ });
508
+ }
509
+
510
+ var headerHost = serverUrl.hostname;
511
+ // Append port number to Host and Origin header, only if specified in the url and non-default
512
+ if(serverUrl.port) {
513
+ if((isSecure && (port != 443)) || (!isSecure && (port != 80))){
514
+ headerHost = headerHost + ':' + port;
515
+ }
516
+ }
517
+
518
+ var requestOptions = {
519
+ port: port,
520
+ host: serverUrl.hostname,
521
+ headers: {
522
+ 'Connection': 'Upgrade',
523
+ 'Upgrade': 'websocket',
524
+ 'Host': headerHost,
525
+ 'Origin': headerHost,
526
+ 'Sec-WebSocket-Version': options.value.protocolVersion,
527
+ 'Sec-WebSocket-Key': key
528
+ }
529
+ };
530
+
531
+ // If we have basic auth.
532
+ if (auth) {
533
+ requestOptions.headers['Authorization'] = 'Basic ' + new Buffer(auth).toString('base64');
534
+ }
535
+
536
+ if (options.value.protocol) {
537
+ requestOptions.headers['Sec-WebSocket-Protocol'] = options.value.protocol;
538
+ }
539
+
540
+ if (options.value.host) {
541
+ requestOptions.headers['Host'] = options.value.host;
542
+ }
543
+
544
+ if (options.value.headers) {
545
+ for (var header in options.value.headers) {
546
+ if (options.value.headers.hasOwnProperty(header)) {
547
+ requestOptions.headers[header] = options.value.headers[header];
548
+ }
549
+ }
550
+ }
551
+
552
+ if (options.isDefinedAndNonNull('pfx')
553
+ || options.isDefinedAndNonNull('key')
554
+ || options.isDefinedAndNonNull('passphrase')
555
+ || options.isDefinedAndNonNull('cert')
556
+ || options.isDefinedAndNonNull('ca')
557
+ || options.isDefinedAndNonNull('ciphers')
558
+ || options.isDefinedAndNonNull('rejectUnauthorized')) {
559
+
560
+ if (isNodeV4) {
561
+ throw new Error('Client side certificates are not supported on Node 0.4.x');
562
+ }
563
+
564
+ if (options.isDefinedAndNonNull('pfx')) requestOptions.pfx = options.value.pfx;
565
+ if (options.isDefinedAndNonNull('key')) requestOptions.key = options.value.key;
566
+ if (options.isDefinedAndNonNull('passphrase')) requestOptions.passphrase = options.value.passphrase;
567
+ if (options.isDefinedAndNonNull('cert')) requestOptions.cert = options.value.cert;
568
+ if (options.isDefinedAndNonNull('ca')) requestOptions.ca = options.value.ca;
569
+ if (options.isDefinedAndNonNull('ciphers')) requestOptions.ciphers = options.value.ciphers;
570
+ if (options.isDefinedAndNonNull('rejectUnauthorized')) requestOptions.rejectUnauthorized = options.value.rejectUnauthorized;
571
+
572
+ if (!agent) {
573
+ // global agent ignores client side certificates
574
+ agent = new httpObj.Agent(requestOptions);
575
+ }
576
+ }
577
+
578
+ if (isNodeV4) {
579
+ requestOptions.path = (serverUrl.pathname || '/') + (serverUrl.search || '');
580
+ }
581
+ else requestOptions.path = serverUrl.path || '/';
582
+
583
+ if (agent) {
584
+ requestOptions.agent = agent;
585
+ }
586
+
587
+ if (isUnixSocket) {
588
+ requestOptions.socketPath = serverUrl.pathname;
589
+ }
590
+ if (options.value.origin) {
591
+ if (options.value.protocolVersion < 13) requestOptions.headers['Sec-WebSocket-Origin'] = options.value.origin;
592
+ else requestOptions.headers['Origin'] = options.value.origin;
593
+ }
594
+
595
+ var self = this;
596
+ var req = httpObj.request(requestOptions);
597
+
598
+ (isNodeV4 ? agent : req).on('error', function(error) {
599
+ self.emit('error', error);
600
+ cleanupWebsocketResources.call(this, error);
601
+ });
602
+ (isNodeV4 ? agent : req).once('response', function(res) {
603
+ var error = new Error('unexpected server response (' + res.statusCode + ')');
604
+ self.emit('error', error);
605
+ cleanupWebsocketResources.call(this, error);
606
+ });
607
+ (isNodeV4 ? agent : req).once('upgrade', function(res, socket, upgradeHead) {
608
+ if (self.readyState == WebSocket.CLOSED) {
609
+ // client closed before server accepted connection
610
+ self.emit('close');
611
+ removeAllListeners(self);
612
+ socket.end();
613
+ return;
614
+ }
615
+ var serverKey = res.headers['sec-websocket-accept'];
616
+ if (typeof serverKey == 'undefined' || serverKey !== expectedServerKey) {
617
+ self.emit('error', 'invalid server key');
618
+ removeAllListeners(self);
619
+ socket.end();
620
+ return;
621
+ }
622
+
623
+ var serverProt = res.headers['sec-websocket-protocol'];
624
+ var protList = (options.value.protocol || "").split(/, */);
625
+ var protError = null;
626
+ if (!options.value.protocol && serverProt) {
627
+ protError = 'server sent a subprotocol even though none requested';
628
+ } else if (options.value.protocol && !serverProt) {
629
+ protError = 'server sent no subprotocol even though requested';
630
+ } else if (serverProt && protList.indexOf(serverProt) === -1) {
631
+ protError = 'server responded with an invalid protocol';
632
+ }
633
+ if (protError) {
634
+ self.emit('error', protError);
635
+ removeAllListeners(self);
636
+ socket.end();
637
+ return;
638
+ } else if (serverProt) {
639
+ self.protocol = serverProt;
640
+ }
641
+
642
+ establishConnection.call(self, Receiver, Sender, socket, upgradeHead);
643
+
644
+ // perform cleanup on http resources
645
+ removeAllListeners(isNodeV4 ? agent : req);
646
+ req = null;
647
+ agent = null;
648
+ });
649
+
650
+ req.end();
651
+ this.readyState = WebSocket.CONNECTING;
652
+ }
653
+
654
+ function establishConnection(ReceiverClass, SenderClass, socket, upgradeHead) {
655
+ this._socket = socket;
656
+ socket.setTimeout(0);
657
+ socket.setNoDelay(true);
658
+ var self = this;
659
+ this._receiver = new ReceiverClass();
660
+
661
+ // socket cleanup handlers
662
+ socket.on('end', cleanupWebsocketResources.bind(this));
663
+ socket.on('close', cleanupWebsocketResources.bind(this));
664
+ socket.on('error', cleanupWebsocketResources.bind(this));
665
+
666
+ // ensure that the upgradeHead is added to the receiver
667
+ function firstHandler(data) {
668
+ if (self.readyState != WebSocket.OPEN) return;
669
+ if (upgradeHead && upgradeHead.length > 0) {
670
+ self.bytesReceived += upgradeHead.length;
671
+ var head = upgradeHead;
672
+ upgradeHead = null;
673
+ self._receiver.add(head);
674
+ }
675
+ dataHandler = realHandler;
676
+ if (data) {
677
+ self.bytesReceived += data.length;
678
+ self._receiver.add(data);
679
+ }
680
+ }
681
+ // subsequent packets are pushed straight to the receiver
682
+ function realHandler(data) {
683
+ if (data) self.bytesReceived += data.length;
684
+ self._receiver.add(data);
685
+ }
686
+ var dataHandler = firstHandler;
687
+ // if data was passed along with the http upgrade,
688
+ // this will schedule a push of that on to the receiver.
689
+ // this has to be done on next tick, since the caller
690
+ // hasn't had a chance to set event handlers on this client
691
+ // object yet.
692
+ process.nextTick(firstHandler);
693
+
694
+ // receiver event handlers
695
+ self._receiver.ontext = function (data, flags) {
696
+ flags = flags || {};
697
+ self.emit('message', data, flags);
698
+ };
699
+ self._receiver.onbinary = function (data, flags) {
700
+ flags = flags || {};
701
+ flags.binary = true;
702
+ self.emit('message', data, flags);
703
+ };
704
+ self._receiver.onping = function(data, flags) {
705
+ flags = flags || {};
706
+ self.pong(data, {mask: !self._isServer, binary: flags.binary === true}, true);
707
+ self.emit('ping', data, flags);
708
+ };
709
+ self._receiver.onpong = function(data, flags) {
710
+ self.emit('pong', data, flags);
711
+ };
712
+ self._receiver.onclose = function(code, data, flags) {
713
+ flags = flags || {};
714
+ self.close(code, data);
715
+ };
716
+ self._receiver.onerror = function(reason, errorCode) {
717
+ // close the connection when the receiver reports a HyBi error code
718
+ self.close(typeof errorCode != 'undefined' ? errorCode : 1002, '');
719
+ self.emit('error', reason, errorCode);
720
+ };
721
+
722
+ // finalize the client
723
+ this._sender = new SenderClass(socket);
724
+ this._sender.on('error', function(error) {
725
+ self.close(1002, '');
726
+ self.emit('error', error);
727
+ });
728
+ this.readyState = WebSocket.OPEN;
729
+ this.emit('open');
730
+
731
+ socket.on('data', dataHandler);
732
+ }
733
+
734
+ function startQueue(instance) {
735
+ instance._queue = instance._queue || [];
736
+ }
737
+
738
+ function executeQueueSends(instance) {
739
+ var queue = instance._queue;
740
+ if (typeof queue == 'undefined') return;
741
+ delete instance._queue;
742
+ for (var i = 0, l = queue.length; i < l; ++i) {
743
+ queue[i]();
744
+ }
745
+ }
746
+
747
+ function sendStream(instance, stream, options, cb) {
748
+ stream.on('data', function(data) {
749
+ if (instance.readyState != WebSocket.OPEN) {
750
+ if (typeof cb == 'function') cb(new Error('not opened'));
751
+ else {
752
+ delete instance._queue;
753
+ instance.emit('error', new Error('not opened'));
754
+ }
755
+ return;
756
+ }
757
+ options.fin = false;
758
+ instance._sender.send(data, options);
759
+ });
760
+ stream.on('end', function() {
761
+ if (instance.readyState != WebSocket.OPEN) {
762
+ if (typeof cb == 'function') cb(new Error('not opened'));
763
+ else {
764
+ delete instance._queue;
765
+ instance.emit('error', new Error('not opened'));
766
+ }
767
+ return;
768
+ }
769
+ options.fin = true;
770
+ instance._sender.send(null, options);
771
+ if (typeof cb == 'function') cb(null);
772
+ });
773
+ }
774
+
775
+ function cleanupWebsocketResources(error) {
776
+ if (this.readyState == WebSocket.CLOSED) return;
777
+ var emitClose = this.readyState != WebSocket.CONNECTING;
778
+ this.readyState = WebSocket.CLOSED;
779
+
780
+ clearTimeout(this._closeTimer);
781
+ this._closeTimer = null;
782
+ if (emitClose) this.emit('close', this._closeCode || 1000, this._closeMessage || '');
783
+
784
+ if (this._socket) {
785
+ removeAllListeners(this._socket);
786
+ // catch all socket error after removing all standard handlers
787
+ var socket = this._socket;
788
+ this._socket.on('error', function() {
789
+ try { socket.destroy(); } catch (e) {}
790
+ });
791
+ try {
792
+ if (!error) this._socket.end();
793
+ else this._socket.destroy();
794
+ }
795
+ catch (e) { /* Ignore termination errors */ }
796
+ this._socket = null;
797
+ }
798
+ if (this._sender) {
799
+ removeAllListeners(this._sender);
800
+ this._sender = null;
801
+ }
802
+ if (this._receiver) {
803
+ this._receiver.cleanup();
804
+ this._receiver = null;
805
+ }
806
+ removeAllListeners(this);
807
+ this.on('error', function() {}); // catch all errors after this
808
+ delete this._queue;
809
+ }
810
+
811
+ function removeAllListeners(instance) {
812
+ if (isNodeV4) {
813
+ // node v4 doesn't *actually* remove all listeners globally,
814
+ // so we do that instead
815
+ instance._events = {};
816
+ }
817
+ else instance.removeAllListeners();
818
+ }