Imported Upstream version 0.1.0
Praveen Arimbrathodiyil
9 years ago
0 | *.gem | |
1 | *.rbc | |
2 | .bundle | |
3 | .config | |
4 | .yardoc | |
5 | Gemfile.lock | |
6 | InstalledFiles | |
7 | _yardoc | |
8 | coverage | |
9 | doc/ | |
10 | lib/bundler/man | |
11 | pkg | |
12 | rdoc | |
13 | spec/reports | |
14 | test/tmp | |
15 | test/version_tmp | |
16 | tmp | |
17 | *.bundle | |
18 | *.so | |
19 | *.o | |
20 | *.a | |
21 | mkmf.log | |
22 | gemfiles/*.lock⏎ |
0 | Metrics/LineLength: | |
1 | Enabled: false | |
2 | ||
3 | Style/EachWithObject: | |
4 | Enabled: false | |
5 | ||
6 | Style/Encoding: | |
7 | EnforcedStyle: when_needed | |
8 | ||
9 | Style/FormatString: | |
10 | Enabled: false | |
11 | ||
12 | Style/HashSyntax: | |
13 | EnforcedStyle: hash_rockets | |
14 | ||
15 | Style/SignalException: | |
16 | EnforcedStyle: only_raise | |
17 | ||
18 | Style/StringLiterals: | |
19 | EnforcedStyle: double_quotes |
0 | fog-vmfusion⏎ |
0 | 2.1.4⏎ |
0 | matrix: | |
1 | include: | |
2 | - rvm: 1.8.7 | |
3 | gemfile: gemfiles/Gemfile.1.9.2- | |
4 | - rvm: 1.9.2 | |
5 | gemfile: gemfiles/Gemfile.1.9.2- | |
6 | - rvm: 1.9.3 | |
7 | gemfile: gemfiles/Gemfile.1.9.3+ | |
8 | - rvm: 2.0.0 | |
9 | gemfile: gemfiles/Gemfile.1.9.3+ | |
10 | - rvm: 2.1.4 | |
11 | gemfile: gemfiles/Gemfile.1.9.3+ | |
12 | env: COVERAGE=true | |
13 | - rvm: ree | |
14 | gemfile: gemfiles/Gemfile.1.9.2- | |
15 | - rvm: jruby | |
16 | gemfile: gemfiles/Gemfile.1.9.3+ |
0 | ## Getting Involved | |
1 | ||
2 | New contributors are always welcome, when it doubt please ask questions. We strive to be an open and welcoming community. Please be nice to one another. | |
3 | ||
4 | ### Coding | |
5 | ||
6 | * Pick a task: | |
7 | * Offer feedback on open [pull requests](https://github.com/fog/fog-vmfusion/pulls). | |
8 | * Review open [issues](https://github.com/fog/fog-vmfusion/issues) for things to help on. | |
9 | * [Create an issue](https://github.com/fog/fog-vmfusion/issues/new) to start a discussion on additions or features. | |
10 | * Fork the project, add your changes and tests to cover them in a topic branch. | |
11 | * Commit your changes and rebase against `fog/fog-vmfusion` to ensure everything is up to date. | |
12 | * [Submit a pull request](https://github.com/fog/fog-vmfusion/compare/) | |
13 | ||
14 | ### Non-Coding | |
15 | ||
16 | * Offer feedback on open [issues](https://github.com/fog/fog-vmfusion/issues). | |
17 | * Organize or volunteer at events.⏎ |
0 | * Carlos Sanchez <csanchez@maestrodev.com> | |
1 | * Cody Herriges <c.a.herriges@gmail.com> | |
2 | * James Herdman <james.herdman@me.com> | |
3 | * Lance Ivy <lance@cainlevy.net> | |
4 | * Kyle Rames <kyle.rames@rackspace.com> | |
5 | * Patrick Debois <Patrick.Debois@jedi.be> | |
6 | * Paul Thornthwaite <paul@brightbox.co.uk> | |
7 | * Paulo Henrique Lopes Ribeiro <plribeiro3000@gmail.com> | |
8 | * Wesley Beary <geemus@gmail.com> |
0 | source 'https://rubygems.org' | |
1 | ||
2 | # Specify your gem's dependencies in fog-vmfusion.gemspec | |
3 | gemspec |
0 | The MIT License (MIT) | |
1 | ||
2 | Copyright (c) 2014-2014 [CONTRIBUTORS.md](https://github.com/fog/fog-vmfusion/blob/master/CONTRIBUTORS.md) | |
3 | ||
4 | Permission is hereby granted, free of charge, to any person obtaining a copy of | |
5 | this software and associated documentation files (the "Software"), to deal in | |
6 | the Software without restriction, including without limitation the rights to | |
7 | use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of | |
8 | the Software, and to permit persons to whom the Software is furnished to do so, | |
9 | subject to the following conditions: | |
10 | ||
11 | The above copyright notice and this permission notice shall be included in all | |
12 | copies or substantial portions of the Software. | |
13 | ||
14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
15 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS | |
16 | FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR | |
17 | COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER | |
18 | IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | |
19 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.⏎ |
0 | # Fog::Vmfusion | |
1 | ||
2 | [![Gem Version](https://badge.fury.io/rb/fog-vmfusion.svg)](http://badge.fury.io/rb/fog-vmfusion) [![Build Status](https://travis-ci.org/fog/fog-vmfusion.svg?branch=master)](https://travis-ci.org/fog/fog-vmfusion) [![Dependency Status](https://gemnasium.com/fog/fog-vmfusion.svg)](https://gemnasium.com/fog/fog-vmfusion) [![Coverage Status](https://img.shields.io/coveralls/fog/fog-vmfusion.svg)](https://coveralls.io/r/fog/fog-vmfusion?branch=master) [![Code Climate](https://codeclimate.com/github/fog/fog-vmfusion.png)](https://codeclimate.com/github/fog/fog-vmfusion) | |
3 | ||
4 | Module for the 'fog' gem to support VMWARE Fusion | |
5 | ||
6 | ## Help Needed | |
7 | ||
8 | This gem needs a maintainer. If you want to work on it, please contact | |
9 | [@geemus](mailto:geemus@gmail.com) or [@plribeiro3000](mailto:plribeiro3000@gmail.com) | |
10 | ||
11 | ## Installation | |
12 | ||
13 | Add this line to your application's Gemfile: | |
14 | ||
15 | ```ruby | |
16 | gem 'fog-vmfusion' | |
17 | ``` | |
18 | ||
19 | And then execute: | |
20 | ||
21 | $ bundle | |
22 | ||
23 | Or install it yourself as: | |
24 | ||
25 | $ gem install fog-vmfusion | |
26 | ||
27 | ## Usage | |
28 | ||
29 | TODO: Write usage instructions here | |
30 | ||
31 | ## Contributing | |
32 | ||
33 | 1. Fork it ( https://github.com/fog/fog-vmfusion/fork ) | |
34 | 2. Create your feature branch (`git checkout -b my-new-feature`) | |
35 | 3. Commit your changes (`git commit -am 'Add some feature'`) | |
36 | 4. Push to the branch (`git push origin my-new-feature`) | |
37 | 5. Create a new Pull Request |
0 | require 'bundler/gem_tasks' | |
1 | require 'rake/testtask' | |
2 | ||
3 | Rake::TestTask.new do |t| | |
4 | t.libs.push %w(spec) | |
5 | t.test_files = FileList['spec/**/*_spec.rb'] | |
6 | t.verbose = true | |
7 | end | |
8 | ||
9 | desc 'Default Task' | |
10 | task :default => :test |
0 | # coding: utf-8 | |
1 | lib = File.expand_path('../lib', __FILE__) | |
2 | $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) | |
3 | require 'fog/vmfusion/version' | |
4 | ||
5 | Gem::Specification.new do |spec| | |
6 | spec.name = "fog-vmfusion" | |
7 | spec.version = Fog::Vmfusion::VERSION | |
8 | spec.authors = %q(Paulo Henrique Lopes Ribeiro) | |
9 | spec.email = %q(plribeiro3000@gmail.com) | |
10 | spec.summary = %q{Module for the 'fog' gem to support VMWARE FUSION.} | |
11 | spec.description = %q{This library can be used as a module for `fog` or as standalone provider | |
12 | to use the VMWARE FUSION in applications.} | |
13 | spec.homepage = "" | |
14 | spec.license = "MIT" | |
15 | ||
16 | files = `git ls-files -z`.split("\x0") | |
17 | files.delete(".hound.yml") | |
18 | spec.files = files | |
19 | ||
20 | spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) } | |
21 | spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) | |
22 | spec.require_paths = ["lib"] | |
23 | ||
24 | spec.add_dependency "fog-core" | |
25 | spec.add_dependency "fission" | |
26 | ||
27 | spec.add_development_dependency "rake" | |
28 | spec.add_development_dependency "minitest" | |
29 | spec.add_development_dependency "turn" | |
30 | spec.add_development_dependency "pry" | |
31 | ||
32 | if RUBY_VERSION.to_f > 1.9 | |
33 | spec.add_development_dependency "coveralls" | |
34 | spec.add_development_dependency "rubocop" | |
35 | end | |
36 | end |
0 | source :rubygems | |
1 | ||
2 | gem 'mime-types', '< 2.0' | |
3 | gem 'nokogiri', '< 1.6' | |
4 | gem 'rest-client', '~> 1.6.8' | |
5 | gem 'fog-core' | |
6 | ||
7 | gemspec :path => '../'⏎ |
0 | source :rubygems | |
1 | ||
2 | gem 'activesupport', '>= 3.0', '< 4' | |
3 | gem 'mime-types', '< 2.0' | |
4 | gem 'fog-core' | |
5 | ||
6 | gemspec :path => '../'⏎ |
0 | module Vmfusion # deviates from other bin stuff to accomodate gem | |
1 | class << self | |
2 | def class_for(key) | |
3 | case key | |
4 | when :compute | |
5 | Fog::Compute::Vmfusion | |
6 | else | |
7 | raise ArgumentError, "Unrecognized service: #{key}" | |
8 | end | |
9 | end | |
10 | ||
11 | def [](service) | |
12 | @@connections ||= Hash.new do |hash, key| | |
13 | hash[key] = case key | |
14 | when :compute | |
15 | Fog::Logger.warning("Vmfusion[:compute] is not recommended, use Compute[:vmfusion] for portability") | |
16 | Fog::Compute.new(:provider => "Vmfusion") | |
17 | else | |
18 | raise ArgumentError, "Unrecognized service: #{key.inspect}" | |
19 | end | |
20 | end | |
21 | @@connections[service] | |
22 | end | |
23 | ||
24 | def available? | |
25 | begin | |
26 | availability=true unless Gem::Specification::find_by_name("fission").nil? | |
27 | rescue Gem::LoadError | |
28 | availability=false | |
29 | rescue | |
30 | availability_gem=Gem.available?("fission") | |
31 | end | |
32 | ||
33 | if availability | |
34 | for service in services | |
35 | for collection in self.class_for(service).collections | |
36 | unless self.respond_to?(collection) | |
37 | self.class_eval <<-EOS, __FILE__, __LINE__ | |
38 | def self.#{collection} | |
39 | self[:#{service}].#{collection} | |
40 | end | |
41 | EOS | |
42 | end | |
43 | end | |
44 | end | |
45 | end | |
46 | availability | |
47 | end | |
48 | ||
49 | def collections | |
50 | services.map {|service| self[service].collections}.flatten.sort_by {|service| service.to_s} | |
51 | end | |
52 | ||
53 | def services | |
54 | Fog::Vmfusion.services | |
55 | end | |
56 | end | |
57 | end |
0 | require "fog/compute/models/server" | |
1 | ||
2 | module Fog | |
3 | module Compute | |
4 | class Vmfusion | |
5 | class Server < Fog::Compute::Server | |
6 | identity :name | |
7 | ||
8 | attribute :ipaddress | |
9 | attribute :power_state | |
10 | attribute :mac_addresses | |
11 | attribute :path | |
12 | ||
13 | attr_accessor :password | |
14 | ||
15 | # There is currently no documented model of creating VMs from scratch | |
16 | # sans Fusion's wizard. | |
17 | def save | |
18 | raise Fog::Errors::Error.new("Creating a new vm is not yet supported") | |
19 | end | |
20 | ||
21 | # Fussion doesn't have the concept of templates so one just clones | |
22 | # regular VMs. | |
23 | def clone(name) | |
24 | requires :raw | |
25 | ||
26 | ::Fission::VM.clone(@raw[:fission].name,name) | |
27 | return service.servers.get(name) | |
28 | end | |
29 | ||
30 | # Destroy, deletes the VM from the local disk but only hard stops the VM | |
31 | # before doing so if you set :force to true. | |
32 | def destroy(options = { :force => false }) | |
33 | requires :raw | |
34 | ||
35 | if ready? | |
36 | if options[:force] | |
37 | stop | |
38 | end | |
39 | end | |
40 | ||
41 | @raw[:fission].delete | |
42 | end | |
43 | ||
44 | # Start is pretty self explanatory...if you pass :headless as true you | |
45 | # won't get a console on launch. | |
46 | def start(options = { :headless => false }) | |
47 | requires :raw | |
48 | ||
49 | unless ready? | |
50 | @raw[:fission].start(:headless => options[:headless]) | |
51 | return true | |
52 | else | |
53 | return false | |
54 | end | |
55 | end | |
56 | ||
57 | # We're covering a lot of bases here with the different ways one can | |
58 | # stop a VM from running. | |
59 | ||
60 | # Stop is a hard stop, like pulling out the power cord. | |
61 | def stop | |
62 | requires :raw | |
63 | ||
64 | if ready? | |
65 | @raw[:fission].stop(:hard => true) | |
66 | return true | |
67 | else | |
68 | return false | |
69 | end | |
70 | end | |
71 | ||
72 | # Halt and poweroff are just synonyms for stop. | |
73 | def halt | |
74 | stop | |
75 | end | |
76 | ||
77 | def poweroff | |
78 | stop | |
79 | end | |
80 | ||
81 | # This is a graceful shutdown but Fusion is only capable of a graceful | |
82 | # shutdown if tools are installed. Fusion does the right thing though | |
83 | # and if graceful can't be initiated it just does a hard stop. | |
84 | def shutdown | |
85 | requires :raw | |
86 | if ready? | |
87 | @raw[:fission].stop | |
88 | return true | |
89 | else | |
90 | return false | |
91 | end | |
92 | end | |
93 | ||
94 | # Attempt a graceful shutdown, wait for the VM to completely shutdown | |
95 | # and then start it again. | |
96 | def reboot | |
97 | if ready? | |
98 | shutdown | |
99 | wait_for { ! ready? } | |
100 | start | |
101 | return true | |
102 | else | |
103 | return false | |
104 | end | |
105 | end | |
106 | ||
107 | # Resuming from suspend is the same thing as start to Fusion. | |
108 | def resume | |
109 | start | |
110 | end | |
111 | ||
112 | def suspend | |
113 | requires :raw | |
114 | if ready? | |
115 | @raw[:fission].suspend | |
116 | return true | |
117 | else | |
118 | return false | |
119 | end | |
120 | end | |
121 | ||
122 | # Fusion VM Metadata. | |
123 | ||
124 | # The power state of the VM is commonly going to be three values; | |
125 | # running, not running, or suspended. | |
126 | def power_state | |
127 | requires :raw | |
128 | @raw[:fission].state.data | |
129 | end | |
130 | ||
131 | def ready? | |
132 | requires :raw | |
133 | @raw[:fission].running?.data | |
134 | end | |
135 | ||
136 | # Path to the VM's vmx file on the local disk. | |
137 | def path | |
138 | requires :raw | |
139 | @raw[:fission].path | |
140 | end | |
141 | ||
142 | # We obtain the first ipaddress. This should generally be a safe | |
143 | # assumption for Fusion. Even if an address is provided via NAT, | |
144 | # bridge, or host only it will by accessible from the host machine the | |
145 | # VM resides on. | |
146 | def ipaddress | |
147 | requires :raw | |
148 | ip(@raw[:fission]) | |
149 | end | |
150 | ||
151 | # Keeping these three methods around for API compatibility reasons. | |
152 | # Makes the vmfusion provider function similar to cloud providers and | |
153 | # the vsphere provider. Future goal is to add an actual private and | |
154 | # public concept. Needs changes to fission and a determination what is | |
155 | # a public or private address here; bridge, nat, host-only. | |
156 | def public_ip_address | |
157 | ipaddress | |
158 | end | |
159 | ||
160 | def private_ip_address | |
161 | ipaddress | |
162 | end | |
163 | ||
164 | def state | |
165 | power_state | |
166 | end | |
167 | ||
168 | # Collecting all mac_addresses the VM has...mostly just because we are | |
169 | # doing the same thing for the vSphere provider. | |
170 | def mac_addresses | |
171 | requires :raw | |
172 | macs(@raw[:fission]) | |
173 | end | |
174 | ||
175 | # Sets up a convenient way to SSH into a Fusion VM using credentials | |
176 | # stored in your .fog file. | |
177 | ||
178 | # Simply spawn an SSH session. | |
179 | def ssh(commands) | |
180 | super(commands, password ? {:password => password} : {}) | |
181 | end | |
182 | ||
183 | # SCP something to our VM. | |
184 | def scp(local_path, remote_path, upload_options = {}) | |
185 | requires :ssh_ip_address, :username | |
186 | ||
187 | scp_options = {} | |
188 | scp_options[:password] = password unless self.password.nil? | |
189 | scp_options[:key_data] = [private_key] if self.private_key | |
190 | ||
191 | Fog::SCP.new(ssh_ip_address, username, scp_options).upload(local_path, remote_path, upload_options) | |
192 | end | |
193 | ||
194 | # Sets up a new SSH key on the VM so one doesn't need to use a password | |
195 | # ever again. | |
196 | def setup(credentials = {}) | |
197 | requires :public_key, :ssh_ip_address, :username | |
198 | ||
199 | credentials[:password] = password unless self.password.nil? | |
200 | credentails[:key_data] = [private_key] if self.private_key | |
201 | ||
202 | commands = [ | |
203 | %{mkdir .ssh}, | |
204 | ] | |
205 | if public_key | |
206 | commands << %{echo "#{public_key}" >> ~/.ssh/authorized_keys} | |
207 | end | |
208 | ||
209 | # wait for domain to be ready | |
210 | Timeout::timeout(360) do | |
211 | begin | |
212 | Timeout::timeout(8) do | |
213 | Fog::SSH.new(ssh_ip_address, username, credentials.merge(:timeout => 4)).run("pwd") | |
214 | end | |
215 | rescue Errno::ECONNREFUSED | |
216 | sleep(2) | |
217 | retry | |
218 | rescue Net::SSH::AuthenticationFailed, Timeout::Error | |
219 | retry | |
220 | end | |
221 | end | |
222 | Fog::SSH.new(ssh_ip_address, username, credentials).run(commands) | |
223 | end | |
224 | ||
225 | private | |
226 | def ip(fission) | |
227 | first_int = fission.network_info.data.keys.first | |
228 | fission.network_info.data[first_int]["ip_address"] | |
229 | end | |
230 | ||
231 | def macs(fission) | |
232 | fission.mac_addresses.data | |
233 | end | |
234 | ||
235 | def raw | |
236 | @raw | |
237 | end | |
238 | ||
239 | def raw=(new_raw) | |
240 | @raw = new_raw | |
241 | ||
242 | raw_attributes = { | |
243 | :name => new_raw[:fission].name, | |
244 | :power_state => new_raw[:state], | |
245 | :ipaddress => ip(new_raw[:fission]), | |
246 | :mac_addresses => macs(new_raw[:fission]), | |
247 | :path => new_raw[:fission].path | |
248 | } | |
249 | ||
250 | merge_attributes(raw_attributes) | |
251 | end | |
252 | end | |
253 | end | |
254 | end | |
255 | end |
0 | module Fog | |
1 | module Compute | |
2 | class Vmfusion | |
3 | class Servers < Fog::Collection | |
4 | model Fog::Compute::Vmfusion::Server | |
5 | ||
6 | def all(filter = nil) | |
7 | data = [] | |
8 | ||
9 | states = ::Fission::VM.all_with_status.data | |
10 | ||
11 | filter = {} if filter.nil? | |
12 | unless filter.key?(:name) | |
13 | vms=::Fission::VM.all.data | |
14 | vms.each do |vm| | |
15 | data << { :raw => { :fission => vm, | |
16 | :state => states[vm.name] } } | |
17 | end | |
18 | else | |
19 | data << { :raw => { :fission => ::Fission::VM.new(filter[:name]), | |
20 | :state => states[filter[:name]] } } | |
21 | end | |
22 | ||
23 | load(data) | |
24 | end | |
25 | ||
26 | def get(name) | |
27 | self.all(:name => name).first | |
28 | end | |
29 | end | |
30 | end | |
31 | end | |
32 | end |
0 | module Fog | |
1 | module Compute | |
2 | class Vmfusion < Fog::Service | |
3 | autoload :Server, File.expand_path("../vmfusion/server", __FILE__) | |
4 | autoload :Servers, File.expand_path("../vmfusion/servers", __FILE__) | |
5 | ||
6 | model_path "fog/compute/vmfusion" | |
7 | ||
8 | model :server | |
9 | collection :servers | |
10 | ||
11 | class Mock | |
12 | def initialize(_options = {}) | |
13 | Fog::Mock.not_implemented | |
14 | end | |
15 | end | |
16 | ||
17 | class Real | |
18 | def initialize(_options = {}) | |
19 | require "fission" | |
20 | rescue LoadError => e | |
21 | retry if require("rubygems") | |
22 | raise e.message | |
23 | end | |
24 | end | |
25 | end | |
26 | end | |
27 | end |
0 | require "fog/core" | |
1 | require File.expand_path("../vmfusion/version", __FILE__) | |
2 | ||
3 | module Fog | |
4 | module Vmfusion | |
5 | extend Fog::Provider | |
6 | ||
7 | service(:compute, "Compute") | |
8 | end | |
9 | ||
10 | module Compute | |
11 | autoload :Vmfusion, File.expand_path("../compute/vmfusion", __FILE__) | |
12 | end | |
13 | end |
0 | --- !ruby/object:Gem::Specification | |
1 | name: fog-vmfusion | |
2 | version: !ruby/object:Gem::Version | |
3 | version: 0.1.0 | |
4 | platform: ruby | |
5 | authors: | |
6 | - Paulo Henrique Lopes Ribeiro | |
7 | autorequire: | |
8 | bindir: bin | |
9 | cert_chain: [] | |
10 | date: 2015-04-04 00:00:00.000000000 Z | |
11 | dependencies: | |
12 | - !ruby/object:Gem::Dependency | |
13 | name: fog-core | |
14 | requirement: !ruby/object:Gem::Requirement | |
15 | requirements: | |
16 | - - ">=" | |
17 | - !ruby/object:Gem::Version | |
18 | version: '0' | |
19 | type: :runtime | |
20 | prerelease: false | |
21 | version_requirements: !ruby/object:Gem::Requirement | |
22 | requirements: | |
23 | - - ">=" | |
24 | - !ruby/object:Gem::Version | |
25 | version: '0' | |
26 | - !ruby/object:Gem::Dependency | |
27 | name: fission | |
28 | requirement: !ruby/object:Gem::Requirement | |
29 | requirements: | |
30 | - - ">=" | |
31 | - !ruby/object:Gem::Version | |
32 | version: '0' | |
33 | type: :runtime | |
34 | prerelease: false | |
35 | version_requirements: !ruby/object:Gem::Requirement | |
36 | requirements: | |
37 | - - ">=" | |
38 | - !ruby/object:Gem::Version | |
39 | version: '0' | |
40 | - !ruby/object:Gem::Dependency | |
41 | name: rake | |
42 | requirement: !ruby/object:Gem::Requirement | |
43 | requirements: | |
44 | - - ">=" | |
45 | - !ruby/object:Gem::Version | |
46 | version: '0' | |
47 | type: :development | |
48 | prerelease: false | |
49 | version_requirements: !ruby/object:Gem::Requirement | |
50 | requirements: | |
51 | - - ">=" | |
52 | - !ruby/object:Gem::Version | |
53 | version: '0' | |
54 | - !ruby/object:Gem::Dependency | |
55 | name: minitest | |
56 | requirement: !ruby/object:Gem::Requirement | |
57 | requirements: | |
58 | - - ">=" | |
59 | - !ruby/object:Gem::Version | |
60 | version: '0' | |
61 | type: :development | |
62 | prerelease: false | |
63 | version_requirements: !ruby/object:Gem::Requirement | |
64 | requirements: | |
65 | - - ">=" | |
66 | - !ruby/object:Gem::Version | |
67 | version: '0' | |
68 | - !ruby/object:Gem::Dependency | |
69 | name: turn | |
70 | requirement: !ruby/object:Gem::Requirement | |
71 | requirements: | |
72 | - - ">=" | |
73 | - !ruby/object:Gem::Version | |
74 | version: '0' | |
75 | type: :development | |
76 | prerelease: false | |
77 | version_requirements: !ruby/object:Gem::Requirement | |
78 | requirements: | |
79 | - - ">=" | |
80 | - !ruby/object:Gem::Version | |
81 | version: '0' | |
82 | - !ruby/object:Gem::Dependency | |
83 | name: pry | |
84 | requirement: !ruby/object:Gem::Requirement | |
85 | requirements: | |
86 | - - ">=" | |
87 | - !ruby/object:Gem::Version | |
88 | version: '0' | |
89 | type: :development | |
90 | prerelease: false | |
91 | version_requirements: !ruby/object:Gem::Requirement | |
92 | requirements: | |
93 | - - ">=" | |
94 | - !ruby/object:Gem::Version | |
95 | version: '0' | |
96 | - !ruby/object:Gem::Dependency | |
97 | name: coveralls | |
98 | requirement: !ruby/object:Gem::Requirement | |
99 | requirements: | |
100 | - - ">=" | |
101 | - !ruby/object:Gem::Version | |
102 | version: '0' | |
103 | type: :development | |
104 | prerelease: false | |
105 | version_requirements: !ruby/object:Gem::Requirement | |
106 | requirements: | |
107 | - - ">=" | |
108 | - !ruby/object:Gem::Version | |
109 | version: '0' | |
110 | - !ruby/object:Gem::Dependency | |
111 | name: rubocop | |
112 | requirement: !ruby/object:Gem::Requirement | |
113 | requirements: | |
114 | - - ">=" | |
115 | - !ruby/object:Gem::Version | |
116 | version: '0' | |
117 | type: :development | |
118 | prerelease: false | |
119 | version_requirements: !ruby/object:Gem::Requirement | |
120 | requirements: | |
121 | - - ">=" | |
122 | - !ruby/object:Gem::Version | |
123 | version: '0' | |
124 | description: |- | |
125 | This library can be used as a module for `fog` or as standalone provider | |
126 | to use the VMWARE FUSION in applications. | |
127 | email: plribeiro3000@gmail.com | |
128 | executables: [] | |
129 | extensions: [] | |
130 | extra_rdoc_files: [] | |
131 | files: | |
132 | - ".gitignore" | |
133 | - ".rubocop.yml" | |
134 | - ".ruby-gemset" | |
135 | - ".ruby-version" | |
136 | - ".travis.yml" | |
137 | - CONTRIBUTING.md | |
138 | - CONTRIBUTORS.md | |
139 | - Gemfile | |
140 | - LICENSE.md | |
141 | - README.md | |
142 | - Rakefile | |
143 | - fog-vmfusion.gemspec | |
144 | - gemfiles/Gemfile.1.9.2- | |
145 | - gemfiles/Gemfile.1.9.3+ | |
146 | - lib/fog/bin/vmfusion.rb | |
147 | - lib/fog/compute/vmfusion.rb | |
148 | - lib/fog/compute/vmfusion/server.rb | |
149 | - lib/fog/compute/vmfusion/servers.rb | |
150 | - lib/fog/vmfusion.rb | |
151 | - lib/fog/vmfusion/version.rb | |
152 | - spec/minitest_helper.rb | |
153 | homepage: '' | |
154 | licenses: | |
155 | - MIT | |
156 | metadata: {} | |
157 | post_install_message: | |
158 | rdoc_options: [] | |
159 | require_paths: | |
160 | - lib | |
161 | required_ruby_version: !ruby/object:Gem::Requirement | |
162 | requirements: | |
163 | - - ">=" | |
164 | - !ruby/object:Gem::Version | |
165 | version: '0' | |
166 | required_rubygems_version: !ruby/object:Gem::Requirement | |
167 | requirements: | |
168 | - - ">=" | |
169 | - !ruby/object:Gem::Version | |
170 | version: '0' | |
171 | requirements: [] | |
172 | rubyforge_project: | |
173 | rubygems_version: 2.4.2 | |
174 | signing_key: | |
175 | specification_version: 4 | |
176 | summary: Module for the 'fog' gem to support VMWARE FUSION. | |
177 | test_files: | |
178 | - spec/minitest_helper.rb |
0 | require 'minitest/spec' | |
1 | require 'minitest/autorun' | |
2 | require 'turn' | |
3 | ||
4 | Turn.config do |c| | |
5 | # use one of output formats: | |
6 | # :outline - turn's original case/test outline mode [default] | |
7 | # :progress - indicates progress with progress bar | |
8 | # :dotted - test/unit's traditional dot-progress mode | |
9 | # :pretty - new pretty reporter | |
10 | # :marshal - dump output as YAML (normal run mode only) | |
11 | # :cue - interactive testing | |
12 | # c.format = :outline | |
13 | # turn on invoke/execute tracing, enable full backtrace | |
14 | c.trace = 20 | |
15 | # use humanized test names (works only with :outline format) | |
16 | c.natural = true | |
17 | end | |
18 | ||
19 | if ENV['COVERAGE'] | |
20 | require 'coveralls' | |
21 | require 'simplecov' | |
22 | ||
23 | SimpleCov.start do | |
24 | add_filter '/spec/' | |
25 | end | |
26 | end | |
27 | ||
28 | require File.join(File.dirname(__FILE__), '../lib/fog/vmfusion.rb') | |
29 | ||
30 | Coveralls.wear! if ENV['COVERAGE'] |