Skip to content

Commit

Permalink
Merge pull request #400 from serverspec/lowercase-specinfra
Browse files Browse the repository at this point in the history
Rename SpecInfra to Specinfra
  • Loading branch information
mizzy committed May 6, 2014
2 parents fdb9906 + aec5a82 commit 2de5bdd
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 20 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,16 +101,16 @@ Serverspec supports Darwin based OS, Red Hat based OS, Debian based OS, Gentoo,

Serverspec can detect target host's OS automatically.

If you'd like to set target host's OS explicitly, you should include `SpecInfra::Helper::OSName` in `spec/spec_helper.rb` like this.
If you'd like to set target host's OS explicitly, you should include `Specinfra::Helper::OSName` in `spec/spec_helper.rb` like this.


```ruby
require 'serverspec'
require 'pathname'
require 'net/ssh'

include SpecInfra::Helper::Ssh
include SpecInfra::Helper::Debian
include Specinfra::Helper::Ssh
include Specinfra::Helper::Debian

RSpec.configure do |c|
# Add SSH before hook in case you use the SSH backend
Expand All @@ -130,12 +130,12 @@ end

You can select from:

* SpecInfra::Helper::RedHat
* SpecInfra::Helper::Debian
* SpecInfra::Helper::Gentoo
* SpecInfra::Helper::Solaris
* SpecInfra::Helper::Darwin
* SpecInfra::Helper::Arch
* Specinfra::Helper::RedHat
* Specinfra::Helper::Debian
* Specinfra::Helper::Gentoo
* Specinfra::Helper::Solaris
* Specinfra::Helper::Darwin
* Specinfra::Helper::Arch

## Vagrant support

Expand Down
2 changes: 1 addition & 1 deletion lib/serverspec/commands/base.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module Serverspec
module Commands
class Base < SpecInfra::Command::Base
class Base < Specinfra::Command::Base
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion lib/serverspec/helper/backend.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module Helper
['Exec', 'Ssh', 'Cmd', 'WinRM'].each do |backend|
eval <<-EOF
module #{backend}
include self.class.const_get('SpecInfra').const_get('Helper').const_get('#{backend}')
include self.class.const_get('Specinfra').const_get('Helper').const_get('#{backend}')
end
EOF
end
Expand Down
2 changes: 1 addition & 1 deletion lib/serverspec/helper/os.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ module Helper
].each do |os|
eval <<-EOF
module #{os}
include self.class.const_get('SpecInfra').const_get('Helper').const_get('#{os}')
include self.class.const_get('Specinfra').const_get('Helper').const_get('#{os}')
end
EOF
end
Expand Down
2 changes: 1 addition & 1 deletion lib/serverspec/helper/properties.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
module Serverspec
module Helper
module Properties
include SpecInfra::Helper::Properties
include Specinfra::Helper::Properties
end
end
end
6 changes: 3 additions & 3 deletions lib/serverspec/setup.rb
Original file line number Diff line number Diff line change
Expand Up @@ -226,11 +226,11 @@ def self.spec_helper_template
require 'winrm'
<% end -%>
include SpecInfra::Helper::<%= @backend_type %>
include Specinfra::Helper::<%= @backend_type %>
<% if @os_type == 'UN*X' -%>
include SpecInfra::Helper::DetectOS
include Specinfra::Helper::DetectOS
<% else -%>
include SpecInfra::Helper::Windows
include Specinfra::Helper::Windows
<% end -%>
<% if @os_type == 'UN*X' -%>
Expand Down
8 changes: 4 additions & 4 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@
require 'pathname'
require 'rspec/mocks/standalone'

include SpecInfra::Helper::Exec
include Specinfra::Helper::Exec

PROJECT_ROOT = (Pathname.new(File.dirname(__FILE__)) + '..').expand_path

Dir[PROJECT_ROOT.join("spec/support/**/*.rb")].each { |file| require(file) }


module SpecInfra
module Specinfra
module Backend
module TestCommandRunner
def do_run cmd
Expand All @@ -18,8 +18,8 @@ def do_run cmd
end

CommandResult.new({
:stdout => ::SpecInfra.configuration.stdout,
:stderr => ::SpecInfra.configuration.stderr,
:stdout => ::Specinfra.configuration.stdout,
:stderr => ::Specinfra.configuration.stderr,
:exit_status => cmd =~ /invalid/ ? 1 : 0,
:exit_signal => nil,
})
Expand Down

0 comments on commit 2de5bdd

Please sign in to comment.