vagrant-unbundled 1.9.7.1 → 1.9.8.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (280) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +36 -0
  3. data/Gemfile.lock +10 -6
  4. data/contrib/bash/completion.sh +1 -1
  5. data/contrib/sudoers/linux-ubuntu +3 -4
  6. data/lib/vagrant/errors.rb +8 -0
  7. data/lib/vagrant/machine.rb +2 -0
  8. data/lib/vagrant/util/platform.rb +1 -1
  9. data/lib/vagrant/util/powershell.rb +42 -13
  10. data/lib/vagrant/util/safe_exec.rb +13 -2
  11. data/lib/vagrant/util/ssh.rb +11 -1
  12. data/plugins/commands/box/command/update.rb +12 -7
  13. data/plugins/commands/login/client.rb +15 -6
  14. data/plugins/commands/login/command.rb +13 -3
  15. data/plugins/commands/up/command.rb +9 -0
  16. data/plugins/commands/validate/command.rb +4 -4
  17. data/plugins/guests/darwin/cap/shell_expand_guest_path.rb +2 -2
  18. data/plugins/guests/freebsd/cap/configure_networks.rb +1 -1
  19. data/plugins/guests/freebsd/cap/shell_expand_guest_path.rb +2 -2
  20. data/plugins/guests/linux/cap/shell_expand_guest_path.rb +2 -2
  21. data/plugins/guests/netbsd/cap/shell_expand_guest_path.rb +2 -2
  22. data/plugins/guests/openbsd/cap/shell_expand_guest_path.rb +2 -2
  23. data/plugins/guests/windows/cap/public_key.rb +21 -45
  24. data/plugins/kernel_v2/config/ssh_connect.rb +3 -0
  25. data/plugins/providers/docker/config.rb +4 -0
  26. data/plugins/providers/docker/driver/compose.rb +11 -4
  27. data/plugins/providers/hyperv/action/wait_for_ip_address.rb +15 -11
  28. data/plugins/providers/hyperv/scripts/get_network_config.ps1 +24 -9
  29. data/plugins/providers/virtualbox/action/prepare_nfs_settings.rb +18 -0
  30. data/plugins/provisioners/ansible/provisioner/host.rb +1 -1
  31. data/plugins/provisioners/chef/cap/debian/chef_install.rb +2 -2
  32. data/plugins/provisioners/chef/cap/freebsd/chef_install.rb +2 -2
  33. data/plugins/provisioners/chef/cap/omnios/chef_install.rb +2 -2
  34. data/plugins/provisioners/chef/cap/redhat/chef_install.rb +2 -2
  35. data/plugins/provisioners/chef/cap/suse/chef_install.rb +2 -2
  36. data/plugins/provisioners/chef/cap/windows/chef_install.rb +2 -2
  37. data/plugins/provisioners/chef/config/base.rb +17 -0
  38. data/plugins/provisioners/chef/config/chef_zero.rb +7 -0
  39. data/plugins/provisioners/chef/installer.rb +8 -7
  40. data/plugins/provisioners/chef/omnibus.rb +4 -6
  41. data/plugins/provisioners/chef/provisioner/base.rb +1 -0
  42. data/plugins/provisioners/chef/provisioner/chef_solo.rb +2 -1
  43. data/plugins/provisioners/file/provisioner.rb +18 -2
  44. data/plugins/provisioners/puppet/provisioner/puppet.rb +0 -2
  45. data/plugins/provisioners/salt/bootstrap-salt.sh +9 -5
  46. data/plugins/provisioners/shell/provisioner.rb +1 -1
  47. data/plugins/synced_folders/rsync/command/rsync_auto.rb +6 -1
  48. data/plugins/synced_folders/rsync/helper.rb +10 -0
  49. data/templates/locales/en.yml +27 -1
  50. data/templates/locales/providers_docker.yml +2 -0
  51. data/test/unit/base.rb +1 -3
  52. data/test/unit/plugins/commands/box/command/add_test.rb +3 -3
  53. data/test/unit/plugins/commands/box/command/remove_test.rb +6 -6
  54. data/test/unit/plugins/commands/box/command/repackage_test.rb +2 -4
  55. data/test/unit/plugins/commands/box/command/update_test.rb +36 -14
  56. data/test/unit/plugins/commands/init/command_test.rb +1 -1
  57. data/test/unit/plugins/commands/list-commands/command_test.rb +2 -2
  58. data/test/unit/plugins/commands/login/client_test.rb +5 -1
  59. data/test/unit/plugins/commands/package/command_test.rb +1 -1
  60. data/test/unit/plugins/commands/plugin/action/expunge_plugins_test.rb +1 -1
  61. data/test/unit/plugins/commands/plugin/action/install_gem_test.rb +3 -3
  62. data/test/unit/plugins/commands/plugin/action/plugin_exists_check_test.rb +3 -3
  63. data/test/unit/plugins/commands/plugin/action/uninstall_plugin_test.rb +1 -1
  64. data/test/unit/plugins/commands/plugin/action/update_gems_test.rb +2 -2
  65. data/test/unit/plugins/commands/port/command_test.rb +3 -3
  66. data/test/unit/plugins/commands/push/command_test.rb +1 -1
  67. data/test/unit/plugins/commands/snapshot/command/list_test.rb +2 -3
  68. data/test/unit/plugins/commands/ssh_config/command_test.rb +1 -1
  69. data/test/unit/plugins/commands/up/command_test.rb +69 -2
  70. data/test/unit/plugins/commands/validate/command_test.rb +47 -1
  71. data/test/unit/plugins/communicators/ssh/communicator_test.rb +5 -5
  72. data/test/unit/plugins/communicators/winrm/communicator_test.rb +6 -6
  73. data/test/unit/plugins/communicators/winrm/helper_test.rb +24 -23
  74. data/test/unit/plugins/communicators/winssh/communicator_test.rb +5 -5
  75. data/test/unit/plugins/guests/darwin/cap/shell_expand_guest_path_test.rb +43 -0
  76. data/test/unit/plugins/guests/freebsd/cap/configure_networks_test.rb +1 -1
  77. data/test/unit/plugins/guests/freebsd/cap/shell_expand_guest_path_test.rb +44 -0
  78. data/test/unit/plugins/guests/linux/cap/shell_expand_guest_path_test.rb +43 -0
  79. data/test/unit/plugins/guests/netbsd/cap/shell_expand_guest_path_test.rb +43 -0
  80. data/test/unit/plugins/guests/omnios/cap/mount_nfs_folder_test.rb +1 -3
  81. data/test/unit/plugins/guests/openbsd/cap/shell_expand_guest_path_test.rb +43 -0
  82. data/test/unit/plugins/guests/smartos/cap/change_host_name_test.rb +2 -2
  83. data/test/unit/plugins/guests/smartos/cap/configure_networks_test.rb +2 -2
  84. data/test/unit/plugins/guests/smartos/cap/halt_test.rb +2 -2
  85. data/test/unit/plugins/guests/smartos/cap/insert_public_key_test.rb +1 -1
  86. data/test/unit/plugins/guests/smartos/cap/mount_nfs_test.rb +2 -2
  87. data/test/unit/plugins/guests/smartos/cap/rsync_test.rb +2 -2
  88. data/test/unit/plugins/guests/windows/cap/insert_public_key_test.rb +2 -2
  89. data/test/unit/plugins/guests/windows/cap/remove_public_key_test.rb +4 -3
  90. data/test/unit/plugins/guests/windows/config_test.rb +1 -1
  91. data/test/unit/plugins/guests/windows/guest_network_test.rb +2 -2
  92. data/test/unit/plugins/hosts/linux/cap/nfs_test.rb +2 -0
  93. data/test/unit/plugins/kernel_v2/config/push_test.rb +1 -1
  94. data/test/unit/plugins/kernel_v2/config/vm_test.rb +7 -7
  95. data/test/unit/plugins/providers/docker/action/create_test.rb +1 -1
  96. data/test/unit/plugins/providers/docker/command/exec_test.rb +1 -1
  97. data/test/unit/plugins/providers/docker/config_test.rb +23 -4
  98. data/test/unit/plugins/providers/docker/driver_compose_test.rb +60 -30
  99. data/test/unit/plugins/providers/docker/driver_test.rb +31 -31
  100. data/test/unit/plugins/providers/docker/synced_folder_test.rb +3 -3
  101. data/test/unit/plugins/providers/hyperv/provider_test.rb +19 -19
  102. data/test/unit/plugins/providers/virtualbox/action/network_fix_ipv6_test.rb +2 -2
  103. data/test/unit/plugins/providers/virtualbox/action/network_test.rb +1 -1
  104. data/test/unit/plugins/providers/virtualbox/action/prepare_nfs_settings_test.rb +34 -8
  105. data/test/unit/plugins/providers/virtualbox/action/prepare_nfs_valid_ids_test.rb +3 -3
  106. data/test/unit/plugins/providers/virtualbox/cap_test.rb +2 -2
  107. data/test/unit/plugins/providers/virtualbox/config_test.rb +6 -6
  108. data/test/unit/plugins/providers/virtualbox/synced_folder_test.rb +6 -8
  109. data/test/unit/plugins/provisioners/ansible/config/guest_test.rb +1 -1
  110. data/test/unit/plugins/provisioners/ansible/config/host_test.rb +4 -4
  111. data/test/unit/plugins/provisioners/ansible/config/shared.rb +2 -2
  112. data/test/unit/plugins/provisioners/ansible/provisioner_test.rb +165 -157
  113. data/test/unit/plugins/provisioners/chef/command_builder_test.rb +2 -2
  114. data/test/unit/plugins/provisioners/chef/config/base_test.rb +13 -0
  115. data/test/unit/plugins/provisioners/chef/config/chef_zero_test.rb +11 -0
  116. data/test/unit/plugins/provisioners/chef/omnibus_test.rb +17 -7
  117. data/test/unit/plugins/provisioners/docker/config_test.rb +2 -1
  118. data/test/unit/plugins/provisioners/docker/provisioner_test.rb +13 -13
  119. data/test/unit/plugins/provisioners/file/provisioner_test.rb +32 -14
  120. data/test/unit/plugins/provisioners/puppet/provisioner/puppet_test.rb +51 -0
  121. data/test/unit/plugins/provisioners/salt/provisioner_test.rb +5 -5
  122. data/test/unit/plugins/provisioners/shell/provisioner_test.rb +35 -4
  123. data/test/unit/plugins/pushes/ftp/adapter_test.rb +1 -0
  124. data/test/unit/plugins/synced_folders/nfs/action_cleanup_test.rb +1 -1
  125. data/test/unit/plugins/synced_folders/nfs/config_test.rb +1 -1
  126. data/test/unit/plugins/synced_folders/rsync/command/rsync_auto_test.rb +44 -12
  127. data/test/unit/plugins/synced_folders/rsync/command/rsync_test.rb +5 -5
  128. data/test/unit/plugins/synced_folders/rsync/helper_test.rb +47 -29
  129. data/test/unit/plugins/synced_folders/rsync/synced_folder_test.rb +5 -5
  130. data/test/unit/vagrant/action/builtin/box_add_test.rb +27 -27
  131. data/test/unit/vagrant/action/builtin/box_check_outdated_test.rb +10 -10
  132. data/test/unit/vagrant/action/builtin/box_remove_test.rb +15 -15
  133. data/test/unit/vagrant/action/builtin/confirm_test.rb +1 -1
  134. data/test/unit/vagrant/action/builtin/graceful_halt_test.rb +2 -2
  135. data/test/unit/vagrant/action/builtin/handle_box_test.rb +8 -8
  136. data/test/unit/vagrant/action/builtin/handle_forwarded_port_collisions_test.rb +1 -1
  137. data/test/unit/vagrant/action/builtin/is_env_set_test.rb +2 -2
  138. data/test/unit/vagrant/action/builtin/is_state_test.rb +6 -6
  139. data/test/unit/vagrant/action/builtin/mixin_synced_folders_test.rb +6 -6
  140. data/test/unit/vagrant/action/builtin/provision_test.rb +1 -1
  141. data/test/unit/vagrant/action/builtin/provisioner_cleanup_test.rb +1 -1
  142. data/test/unit/vagrant/action/builtin/synced_folder_cleanup_test.rb +6 -6
  143. data/test/unit/vagrant/action/builtin/synced_folders_test.rb +3 -3
  144. data/test/unit/vagrant/batch_action_test.rb +2 -2
  145. data/test/unit/vagrant/box_collection_test.rb +1 -1
  146. data/test/unit/vagrant/box_test.rb +6 -6
  147. data/test/unit/vagrant/capability_host_test.rb +3 -3
  148. data/test/unit/vagrant/cli_test.rb +3 -3
  149. data/test/unit/vagrant/environment_test.rb +21 -20
  150. data/test/unit/vagrant/guest_test.rb +7 -7
  151. data/test/unit/vagrant/machine_index_test.rb +4 -4
  152. data/test/unit/vagrant/machine_test.rb +28 -17
  153. data/test/unit/vagrant/plugin/manager_test.rb +12 -12
  154. data/test/unit/vagrant/plugin/state_file_test.rb +2 -2
  155. data/test/unit/vagrant/plugin/v1/command_test.rb +9 -8
  156. data/test/unit/vagrant/plugin/v2/command_test.rb +54 -43
  157. data/test/unit/vagrant/plugin/v2/plugin_test.rb +4 -3
  158. data/test/unit/vagrant/plugin/v2/provider_test.rb +3 -3
  159. data/test/unit/vagrant/shared_helpers_test.rb +6 -6
  160. data/test/unit/vagrant/ui_test.rb +21 -21
  161. data/test/unit/vagrant/util/downloader_test.rb +7 -7
  162. data/test/unit/vagrant/util/ssh_test.rb +41 -5
  163. data/test/unit/vagrant/util/subprocess_test.rb +7 -7
  164. data/test/unit/vagrant_test.rb +9 -9
  165. data/vagrant.gemspec +3 -2
  166. data/vendor/bundle/ruby/2.4.0/bundler/gems/vagrant-spec-af86757912f7/vagrant-spec.gemspec +1 -1
  167. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/.gitignore +7 -0
  168. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/.rspec +2 -0
  169. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/.travis.yml +5 -0
  170. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/CONTRIBUTORS.md +19 -0
  171. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/Gemfile +12 -0
  172. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/Gemfile.lock +44 -0
  173. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/Guardfile +10 -0
  174. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/README.md +134 -0
  175. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/Rakefile +10 -0
  176. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/fake_ftp.gemspec +22 -0
  177. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/lib/fake_ftp.rb +5 -0
  178. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/lib/fake_ftp/file.rb +34 -0
  179. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/lib/fake_ftp/server.rb +340 -0
  180. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/lib/fake_ftp/version.rb +3 -0
  181. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/fixtures/invisible_bike.jpg +0 -0
  182. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/fixtures/text_file.txt +1 -0
  183. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/functional/server_spec.rb +468 -0
  184. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/integration/server_spec.rb +81 -0
  185. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/models/fake_ftp/file_spec.rb +102 -0
  186. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/models/fake_ftp/server_spec.rb +76 -0
  187. data/vendor/bundle/ruby/2.4.0/gems/fake_ftp-0.1.1/spec/spec_helper.rb +18 -0
  188. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/.gitignore +14 -0
  189. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/.rubocop.yml +57 -0
  190. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/.travis.yml +21 -0
  191. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/CONTRIBUTING.rdoc +36 -0
  192. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/Gemfile +3 -0
  193. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/History.rdoc +2247 -0
  194. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/MIT-LICENSE +21 -0
  195. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/README.rdoc +156 -0
  196. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/Rakefile +38 -0
  197. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/appveyor.yml +21 -0
  198. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/bin/console +7 -0
  199. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/bin/setup +6 -0
  200. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/command_line_usage.rdoc +158 -0
  201. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/example/Rakefile1 +38 -0
  202. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/example/Rakefile2 +35 -0
  203. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/example/a.c +6 -0
  204. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/example/b.c +6 -0
  205. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/example/main.c +11 -0
  206. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/glossary.rdoc +42 -0
  207. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/jamis.rb +591 -0
  208. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/proto_rake.rdoc +127 -0
  209. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/rake.1 +156 -0
  210. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/rakefile.rdoc +622 -0
  211. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/doc/rational.rdoc +151 -0
  212. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/exe/rake +27 -0
  213. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake.rb +70 -0
  214. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/application.rb +785 -0
  215. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/backtrace.rb +23 -0
  216. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/clean.rb +77 -0
  217. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/cloneable.rb +16 -0
  218. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/cpu_counter.rb +106 -0
  219. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/default_loader.rb +14 -0
  220. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/dsl_definition.rb +194 -0
  221. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/early_time.rb +21 -0
  222. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/ext/core.rb +25 -0
  223. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/ext/string.rb +175 -0
  224. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/file_creation_task.rb +24 -0
  225. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/file_list.rb +434 -0
  226. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/file_task.rb +46 -0
  227. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/file_utils.rb +136 -0
  228. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/file_utils_ext.rb +144 -0
  229. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/invocation_chain.rb +56 -0
  230. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/invocation_exception_mixin.rb +16 -0
  231. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/late_time.rb +17 -0
  232. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/linked_list.rb +111 -0
  233. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/loaders/makefile.rb +53 -0
  234. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/multi_task.rb +49 -0
  235. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/name_space.rb +37 -0
  236. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/packagetask.rb +210 -0
  237. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/phony.rb +15 -0
  238. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/private_reader.rb +20 -0
  239. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/promise.rb +99 -0
  240. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/pseudo_status.rb +29 -0
  241. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/rake_module.rb +38 -0
  242. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/rake_test_loader.rb +21 -0
  243. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/rule_recursion_overflow_error.rb +19 -0
  244. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/scope.rb +42 -0
  245. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/task.rb +390 -0
  246. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/task_argument_error.rb +7 -0
  247. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/task_arguments.rb +108 -0
  248. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/task_manager.rb +303 -0
  249. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/tasklib.rb +11 -0
  250. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/testtask.rb +222 -0
  251. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/thread_history_display.rb +48 -0
  252. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/thread_pool.rb +162 -0
  253. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/trace_output.rb +22 -0
  254. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/version.rb +9 -0
  255. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/lib/rake/win32.rb +50 -0
  256. data/vendor/bundle/ruby/2.4.0/gems/rake-12.0.0/rake.gemspec +39 -0
  257. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/.gitignore +19 -0
  258. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/.rspec +3 -0
  259. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/.travis.yml +24 -0
  260. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/Changelog.md +49 -0
  261. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/Gemfile +26 -0
  262. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/LICENSE.txt +27 -0
  263. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/README.md +72 -0
  264. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/Rakefile +16 -0
  265. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/cucumber.yml +2 -0
  266. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/features/its.feature +125 -0
  267. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/features/step_definitions/additional_cli_steps.rb +21 -0
  268. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/features/support/env.rb +23 -0
  269. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/lib/rspec/its.rb +149 -0
  270. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/lib/rspec/its/version.rb +5 -0
  271. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/rspec-its.gemspec +28 -0
  272. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/script/test_all +20 -0
  273. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/spec/rspec/its_spec.rb +237 -0
  274. data/vendor/bundle/ruby/2.4.0/gems/rspec-its-1.2.0/spec/spec_helper.rb +15 -0
  275. data/vendor/bundle/ruby/2.4.0/specifications/fake_ftp-0.1.1.gemspec +20 -0
  276. data/vendor/bundle/ruby/2.4.0/specifications/rake-12.0.0.gemspec +43 -0
  277. data/vendor/bundle/ruby/2.4.0/specifications/rspec-its-1.2.0.gemspec +47 -0
  278. data/version.txt +1 -1
  279. metadata +137 -7
  280. data/2.14.0 +0 -5
@@ -9,8 +9,8 @@ describe Vagrant::Util::Downloader do
9
9
 
10
10
  let(:subprocess_result) do
11
11
  double("subprocess_result").tap do |result|
12
- result.stub(exit_code: exit_code)
13
- result.stub(stderr: "")
12
+ allow(result).to receive(:exit_code).and_return(exit_code)
13
+ allow(result).to receive(:stderr).and_return("")
14
14
  end
15
15
  end
16
16
 
@@ -69,7 +69,7 @@ describe Vagrant::Util::Downloader do
69
69
  with("curl", *curl_options).
70
70
  and_return(subprocess_result)
71
71
 
72
- expect(subject.download!).to be_true
72
+ expect(subject.download!).to be(true)
73
73
  end
74
74
  end
75
75
 
@@ -90,7 +90,7 @@ describe Vagrant::Util::Downloader do
90
90
  with("curl", *curl_options).
91
91
  and_return(subprocess_result)
92
92
 
93
- expect(subject.download!).to be_true
93
+ expect(subject.download!).to be(true)
94
94
  end
95
95
  end
96
96
 
@@ -116,7 +116,7 @@ describe Vagrant::Util::Downloader do
116
116
  end
117
117
 
118
118
  it "should not raise an exception" do
119
- expect(subject.download!).to be_true
119
+ expect(subject.download!).to be(true)
120
120
  end
121
121
  end
122
122
 
@@ -144,7 +144,7 @@ describe Vagrant::Util::Downloader do
144
144
  end
145
145
 
146
146
  it "should not raise an exception" do
147
- expect(subject.download!).to be_true
147
+ expect(subject.download!).to be(true)
148
148
  end
149
149
  end
150
150
 
@@ -199,7 +199,7 @@ describe Vagrant::Util::Downloader do
199
199
  }
200
200
 
201
201
  it "returns the output" do
202
- subprocess_result.stub(stdout: "foo")
202
+ allow(subprocess_result).to receive(:stdout).and_return("foo")
203
203
 
204
204
  options = curl_options.dup
205
205
  options.unshift("-I")
@@ -67,7 +67,7 @@ describe Vagrant::Util::SSH do
67
67
 
68
68
  expect(described_class.exec(ssh_info)).to eq(nil)
69
69
  expect(Vagrant::Util::SafeExec).to have_received(:exec)
70
- .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL","-o", "Compression=yes", "-o", "DSAAuthentication=yes", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-i", anything)
70
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL","-o", "Compression=yes", "-o", "DSAAuthentication=yes", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}")
71
71
  end
72
72
 
73
73
  context "when disabling compression or dsa_authentication flags" do
@@ -85,7 +85,7 @@ describe Vagrant::Util::SSH do
85
85
 
86
86
  expect(described_class.exec(ssh_info)).to eq(nil)
87
87
  expect(Vagrant::Util::SafeExec).to have_received(:exec)
88
- .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-i", anything)
88
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}")
89
89
  end
90
90
  end
91
91
 
@@ -103,7 +103,7 @@ describe Vagrant::Util::SSH do
103
103
 
104
104
  expect(described_class.exec(ssh_info)).to eq(nil)
105
105
  expect(Vagrant::Util::SafeExec).to have_received(:exec)
106
- .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-i", anything)
106
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}")
107
107
  end
108
108
  end
109
109
 
@@ -140,7 +140,7 @@ describe Vagrant::Util::SSH do
140
140
 
141
141
  expect(described_class.exec(ssh_info)).to eq(nil)
142
142
  expect(Vagrant::Util::SafeExec).to have_received(:exec)
143
- .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-i", anything,"-o", "ForwardX11=yes", "-o", "ForwardX11Trusted=yes")
143
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}","-o", "ForwardX11=yes", "-o", "ForwardX11Trusted=yes")
144
144
  end
145
145
  end
146
146
 
@@ -158,7 +158,43 @@ describe Vagrant::Util::SSH do
158
158
 
159
159
  expect(described_class.exec(ssh_info)).to eq(nil)
160
160
  expect(Vagrant::Util::SafeExec).to have_received(:exec)
161
- .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-i", anything,"-o", "ForwardAgent=yes")
161
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}","-o", "ForwardAgent=yes")
162
+ end
163
+ end
164
+
165
+ context "when extra_args is provided as an array" do
166
+ let(:ssh_info) {{
167
+ host: "localhost",
168
+ port: 2222,
169
+ username: "vagrant",
170
+ private_key_path: [temporary_file],
171
+ extra_args: ["-L", "8008:localhost:80"]
172
+ }}
173
+
174
+ it "enables agent forwarding options" do
175
+ allow(Vagrant::Util::SafeExec).to receive(:exec).and_return(nil)
176
+
177
+ expect(described_class.exec(ssh_info)).to eq(nil)
178
+ expect(Vagrant::Util::SafeExec).to have_received(:exec)
179
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}", "-L", "8008:localhost:80")
180
+ end
181
+ end
182
+
183
+ context "when extra_args is provided as a string" do
184
+ let(:ssh_info) {{
185
+ host: "localhost",
186
+ port: 2222,
187
+ username: "vagrant",
188
+ private_key_path: [temporary_file],
189
+ extra_args: "-6"
190
+ }}
191
+
192
+ it "enables agent forwarding options" do
193
+ allow(Vagrant::Util::SafeExec).to receive(:exec).and_return(nil)
194
+
195
+ expect(described_class.exec(ssh_info)).to eq(nil)
196
+ expect(Vagrant::Util::SafeExec).to have_received(:exec)
197
+ .with("ssh", "vagrant@localhost", "-p", "2222", "-o", "LogLevel=FATAL", "-o", "StrictHostKeyChecking=no", "-o", "UserKnownHostsFile=/dev/null", "-o", "IdentityFile=#{ssh_info[:private_key_path][0]}", "-6")
162
198
  end
163
199
  end
164
200
 
@@ -52,14 +52,14 @@ describe Vagrant::Util::Subprocess do
52
52
  context "when subprocess has not been started" do
53
53
  it "should return false" do
54
54
  sp = described_class.new("ls")
55
- expect(sp.running?).to be_false
55
+ expect(sp.running?).to be(false)
56
56
  end
57
57
  end
58
58
  context "when subprocess has completed" do
59
59
  it "should return false" do
60
60
  sp = described_class.new("ls")
61
61
  sp.execute
62
- expect(sp.running?).to be_false
62
+ expect(sp.running?).to be(false)
63
63
  end
64
64
  end
65
65
  context "when subprocess is running" do
@@ -67,7 +67,7 @@ describe Vagrant::Util::Subprocess do
67
67
  sp = described_class.new("sleep", "5")
68
68
  thread = Thread.new{ sp.execute }
69
69
  sleep(0.3)
70
- expect(sp.running?).to be_true
70
+ expect(sp.running?).to be(true)
71
71
  sp.stop
72
72
  thread.join
73
73
  end
@@ -78,7 +78,7 @@ describe Vagrant::Util::Subprocess do
78
78
  context "when subprocess has not been started" do
79
79
  it "should return false" do
80
80
  sp = described_class.new("ls")
81
- expect(sp.stop).to be_false
81
+ expect(sp.stop).to be(false)
82
82
  end
83
83
  end
84
84
 
@@ -86,7 +86,7 @@ describe Vagrant::Util::Subprocess do
86
86
  it "should return false" do
87
87
  sp = described_class.new("ls")
88
88
  sp.execute
89
- expect(sp.stop).to be_false
89
+ expect(sp.stop).to be(false)
90
90
  end
91
91
  end
92
92
 
@@ -95,7 +95,7 @@ describe Vagrant::Util::Subprocess do
95
95
  it "should return true" do
96
96
  thread = Thread.new{ sp.execute }
97
97
  sleep(0.1)
98
- expect(sp.stop).to be_true
98
+ expect(sp.stop).to be(true)
99
99
  thread.join
100
100
  end
101
101
 
@@ -103,7 +103,7 @@ describe Vagrant::Util::Subprocess do
103
103
  thread = Thread.new{ sp.execute }
104
104
  sleep(0.1)
105
105
  sp.stop
106
- expect(sp.running?).to be_false
106
+ expect(sp.running?).to be(false)
107
107
  thread.join
108
108
  end
109
109
  end
@@ -59,31 +59,31 @@ describe Vagrant do
59
59
  name "i_am_installed"
60
60
  end
61
61
 
62
- expect(described_class.has_plugin?("i_am_installed")).to be_true
62
+ expect(described_class.has_plugin?("i_am_installed")).to be(true)
63
63
  end
64
64
 
65
65
  it "should return false if the plugin is not installed" do
66
- expect(described_class.has_plugin?("i_dont_exist")).to be_false
66
+ expect(described_class.has_plugin?("i_dont_exist")).to be(false)
67
67
  end
68
68
 
69
69
  it "finds plugins by gem name" do
70
70
  specs = [Gem::Specification.new]
71
71
  specs[0].name = "foo"
72
- Vagrant::Plugin::Manager.instance.stub(installed_specs: specs)
72
+ allow(Vagrant::Plugin::Manager.instance).to receive(:installed_specs).and_return(specs)
73
73
 
74
- expect(described_class.has_plugin?("foo")).to be_true
75
- expect(described_class.has_plugin?("bar")).to be_false
74
+ expect(described_class.has_plugin?("foo")).to be(true)
75
+ expect(described_class.has_plugin?("bar")).to be(false)
76
76
  end
77
77
 
78
78
  it "finds plugins by gem name and version" do
79
79
  specs = [Gem::Specification.new]
80
80
  specs[0].name = "foo"
81
81
  specs[0].version = "1.2.3"
82
- Vagrant::Plugin::Manager.instance.stub(installed_specs: specs)
82
+ allow(Vagrant::Plugin::Manager.instance).to receive(:installed_specs).and_return(specs)
83
83
 
84
- expect(described_class.has_plugin?("foo", "~> 1.2.0")).to be_true
85
- expect(described_class.has_plugin?("foo", "~> 1.0.0")).to be_false
86
- expect(described_class.has_plugin?("bar", "~> 1.2.0")).to be_false
84
+ expect(described_class.has_plugin?("foo", "~> 1.2.0")).to be(true)
85
+ expect(described_class.has_plugin?("foo", "~> 1.0.0")).to be(false)
86
+ expect(described_class.has_plugin?("bar", "~> 1.2.0")).to be(false)
87
87
  end
88
88
  end
89
89
 
data/vagrant.gemspec CHANGED
@@ -39,10 +39,11 @@ Gem::Specification.new do |s|
39
39
 
40
40
  # Constraint rake to properly handle deprecated method usage
41
41
  # from within rspec
42
- s.add_development_dependency "rake", "~> 11.3.0"
42
+ s.add_development_dependency "rake", "~> 12.0.0"
43
43
  s.add_development_dependency "rspec", "~> 3.5.0"
44
+ s.add_development_dependency "rspec-its", "~> 1.2.0"
44
45
  s.add_development_dependency "webmock", "~> 1.20"
45
- s.add_development_dependency "fake_ftp", "~> 0.1"
46
+ s.add_development_dependency "fake_ftp", "~> 0.1.1"
46
47
 
47
48
  # The following block of code determines the files that should be included
48
49
  # in the gem. It does this by reading all the files in the directory where
@@ -8,7 +8,7 @@ Gem::Specification.new do |s|
8
8
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
9
9
  s.require_paths = ["lib".freeze]
10
10
  s.authors = ["Mitchell Hashimoto".freeze]
11
- s.date = "2017-08-14"
11
+ s.date = "2017-08-31"
12
12
  s.description = "Tool and library for testing Vagrant plugins".freeze
13
13
  s.email = ["mitchell.hashimoto@gmail.com".freeze]
14
14
  s.executables = ["vagrant-spec".freeze]
@@ -0,0 +1,7 @@
1
+ .idea
2
+ pkg/*
3
+ *.gem
4
+ .bundle
5
+ .DS_Store
6
+ .rbenv-version
7
+ .rbenv-gemsets
@@ -0,0 +1,2 @@
1
+ --color
2
+ --format documentation
@@ -0,0 +1,5 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.0.0
4
+ - 1.9.3
5
+ - 1.8.7
@@ -0,0 +1,19 @@
1
+ Contributors
2
+ ============
3
+
4
+ * Eric Saxby - @sax
5
+
6
+ * Ben Ashford
7
+ * Colin Shield
8
+ * Eirik Lied
9
+ * Eric Oestrich
10
+ * Jacob Maine
11
+ * John Maxwell
12
+ * Kevin Thompson
13
+ * liehann
14
+ * mdalton
15
+ * Nick Rowe
16
+ * Pranas Kiziela
17
+ * Puneet Goyal
18
+ * Steve Thompson
19
+ * Thomas Sonntag
@@ -0,0 +1,12 @@
1
+ source "http://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in fake_ftp.gemspec
4
+ gemspec
5
+
6
+ group :test do
7
+ gem "rspec", '>2'
8
+ gem "rake", '>=0.8.7'
9
+
10
+ gem "guard-rspec"
11
+ gem 'pry-nav'
12
+ end
@@ -0,0 +1,44 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ fake_ftp (0.1.0)
5
+
6
+ GEM
7
+ remote: http://rubygems.org/
8
+ specs:
9
+ coderay (1.0.9)
10
+ diff-lcs (1.2.4)
11
+ ffi (1.0.11)
12
+ guard (1.0.1)
13
+ ffi (>= 0.5.0)
14
+ thor (~> 0.14.6)
15
+ guard-rspec (0.6.0)
16
+ guard (>= 0.10.0)
17
+ method_source (0.8.2)
18
+ pry (0.9.12.2)
19
+ coderay (~> 1.0.5)
20
+ method_source (~> 0.8)
21
+ slop (~> 3.4)
22
+ pry-nav (0.2.3)
23
+ pry (~> 0.9.10)
24
+ rake (0.9.2.2)
25
+ rspec (2.14.1)
26
+ rspec-core (~> 2.14.0)
27
+ rspec-expectations (~> 2.14.0)
28
+ rspec-mocks (~> 2.14.0)
29
+ rspec-core (2.14.5)
30
+ rspec-expectations (2.14.3)
31
+ diff-lcs (>= 1.1.3, < 2.0)
32
+ rspec-mocks (2.14.3)
33
+ slop (3.4.6)
34
+ thor (0.14.6)
35
+
36
+ PLATFORMS
37
+ ruby
38
+
39
+ DEPENDENCIES
40
+ fake_ftp!
41
+ guard-rspec
42
+ pry-nav
43
+ rake (>= 0.8.7)
44
+ rspec (> 2)
@@ -0,0 +1,10 @@
1
+ # A sample Guardfile
2
+ # More info at https://github.com/guard/guard#readme
3
+
4
+ guard 'rspec', :version => 2 do
5
+ watch(%r{^spec/.+_spec\.rb$})
6
+ watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
7
+ watch('spec/spec_helper.rb') { "spec" }
8
+ watch(%r{^spec/support/(.+)\.rb$}) { "spec" }
9
+ end
10
+
@@ -0,0 +1,134 @@
1
+ FakeFtp
2
+ =======
3
+
4
+ [![Build status](https://secure.travis-ci.org/livinginthepast/fake_ftp.png)](http://travis-ci.org/livinginthepast/fake_ftp)
5
+
6
+ This is a gem that allows you to test FTP implementations in ruby. It is
7
+ a minimal single-client FTP server that can be bound to any arbitrary
8
+ port on localhost.
9
+
10
+
11
+ ## Why?
12
+
13
+ We want to ensure that our code works, in a way that is agnostic to the
14
+ implementation used (unlike with stubs or mocks).
15
+
16
+
17
+ ## How
18
+
19
+ FakeFtp is a simple FTP server that fakes out enough of the protocol to
20
+ get us by, allowing us to test that files get to their intended destination
21
+ rather than testing how our code does so.
22
+
23
+
24
+ ## Usage
25
+
26
+ To test passive upload:
27
+ ``` ruby
28
+ require 'fake_ftp'
29
+ require 'net/ftp'
30
+
31
+ server = FakeFtp::Server.new(21212, 21213)
32
+ ## 21212 is the control port, which is used by FTP for the primary connection
33
+ ## 21213 is the data port, used in FTP passive mode to send file contents
34
+ server.start
35
+
36
+ ftp = Net::FTP.new
37
+ ftp.connect('127.0.0.1', 21212)
38
+ ftp.login('user', 'password')
39
+ ftp.passive = true
40
+ ftp.put('some_file.txt')
41
+ ftp.close
42
+
43
+ server.files.should include('some_file.txt')
44
+ server.file('some_file.txt').bytes.should == 25
45
+ server.file('some_file.txt').should be_passive
46
+ server.file('some_file.txt').should_not be_active
47
+
48
+ server.stop
49
+ ```
50
+
51
+ To test active upload:
52
+ ``` ruby
53
+ server = FakeFtp::Server.new(21212)
54
+ ## 21212 is the control port, which is used by FTP for the primary connection
55
+ ## 21213 is the data port, used in FTP passive mode to send file contents
56
+ server.start
57
+
58
+ ftp = Net::FTP.new
59
+ ftp.connect('127.0.0.1', 21212)
60
+ ftp.login('user', 'password')
61
+ ftp.passive = false
62
+ ftp.put('some_file.txt')
63
+ ftp.close
64
+
65
+ server.files.should include('some_file.txt')
66
+ server.file('some_file.txt').bytes.should == 25
67
+ server.file('some_file.txt').should be_active
68
+ server.file('some_file.txt').should_not be_passive
69
+
70
+ server.stop
71
+ ```
72
+
73
+ Note that many FTP clients default to active, unless specified otherwise.
74
+
75
+
76
+ ## Caveats
77
+
78
+ This is *not* a real FTP server and should not be treated as one. The goal
79
+ of this gem is not to create a thread-safe multi-client implementation.
80
+ It is best used to unit test models that generate files and transfer
81
+ them to an FTP server.
82
+
83
+ As such, there are some things that won't be accepted upstream from pull
84
+ requests:
85
+ * simultaneous multi-client code
86
+ * support for long term file persistence
87
+ * binding to arbitrary IPs
88
+ * global state beyond that required to pass the minimum required to
89
+ generate passing tests
90
+
91
+
92
+ ## Recommendations for testing patterns
93
+
94
+ *Separate configuration from code.* Do not hard code the IP address,
95
+ FQDN or port of an FTP server in your classes. It introduces fragility
96
+ into your tests. Also, the default FTP port of 21 is a privileged port,
97
+ and should be avoided.
98
+
99
+ *Separate the code that generates files from the code that uploads
100
+ files.* You tests will run much more quickly if you only try to upload
101
+ small files. If you have tests showing that you generate correct files
102
+ from your data, then you can trust that. Why do you need to upload a 20M
103
+ file in your tests if you can stub out your file generation method and
104
+ test file upload against 10 bytes? Fast fast fast.
105
+
106
+
107
+ ## References
108
+
109
+ * http://rubyforge.org/projects/ftpd/ - a simple ftp daemon written by Chris Wanstrath
110
+ * http://ruby-doc.org/stdlib/libdoc/gserver/rdoc/index.html - a generic server in the Ruby standard library, by John W Small
111
+
112
+ ## License
113
+
114
+ The MIT License
115
+
116
+ Copyright (c) 2011 Eric Saxby
117
+
118
+ Permission is hereby granted, free of charge, to any person obtaining a copy
119
+ of this software and associated documentation files (the "Software"), to deal
120
+ in the Software without restriction, including without limitation the rights
121
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
122
+ copies of the Software, and to permit persons to whom the Software is
123
+ furnished to do so, subject to the following conditions:
124
+
125
+ The above copyright notice and this permission notice shall be included in
126
+ all copies or substantial portions of the Software.
127
+
128
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
129
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
130
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
131
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
132
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
133
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
134
+ THE SOFTWARE.