beaker-vagrant 0.1.1 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NjdmOThiM2U4ZWQ2NjU3NTk2YTQ5ZmIyOTg5OTBiYWMxYmI0MDY1NA==
4
+ Y2U0MmM2YjliMGU4NDMyM2Y1YjJhYjI0YjQxN2RiMjA2MjUzZWVhYQ==
5
5
  data.tar.gz: !binary |-
6
- MmQ1YmY2ZTIxZDI3YTIxODVmYmE1MmU3YWNlZGIzOGY5YzllZTA2Mw==
6
+ MmZmNWM2NzczNWIwMzk5NmFmMWFmZjFiYWFiODkyNmQyOTNkMzRmNQ==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NTgxOTU3Y2Q2YWYxNGE3YjkzNDliNGU1YWU0MWQ3MmY5MDAxZWMzNWFjNjYz
10
- Y2I1MGEwNzhlNTZhNTUxZjA3NmFiZmFjNjlhNDk1MzJlOTQxYjNmMGZkNWJl
11
- NzFiOWYxMDhkNWJiZGI4NjQ0MTdjZDE3Y2UxZjRmNGZkMWY4YmQ=
9
+ ZmJhZWE4OTljNmQ1YTExMmRhZDI2M2YyNWFkMDliYjUxZGQyOGFjMWZjMjli
10
+ ZDhmN2JmYmJjMmU2NDBmZjNkZGY1ZjhhZWU0Zjc3NTU2MWZlMDFlMTJkNTI4
11
+ MGM3OTBlODdhYWU3OWIyMjA1Y2NlODEyYjVhMDA1NjliMTU4Yzk=
12
12
  data.tar.gz: !binary |-
13
- MzhmZTU5MzU5M2EzNWE5ODI2MGI0NzEyZmJmNzlhYzNjODJiYWE4YjIxNTA2
14
- ZTlkZDJmNmIxYjAzYWFiYjU3NDE3NTdkOTRjYWNjYjUxZDdjZDZkMDQ5M2Vi
15
- N2FlYzU0NzY3Yzg4ODRlM2I0YjFhMTEyMmE4ZGY4ZGMzYTYwMTc=
13
+ OGQxMDAxZmY2NDVlNDMyZTFjNThiMjU0MmFhYTQ4YTBjZjgxMDIyYjFjMTFh
14
+ YjkwMWFjZWU2MWUwNjA0ODJhYTU3OGNjYTg1YmExNmIwMDBmYTFkMzM4NTlm
15
+ MzA2MzVlMTVkOTVkZTExYWQxNTZkZmIzNWUyMGQ2MGE2YWRmMGM=
@@ -1,3 +1,3 @@
1
1
  module BeakerVagrant
2
- VERSION = '0.1.1'
2
+ VERSION = '0.2.0'
3
3
  end
@@ -39,6 +39,7 @@ module Beaker
39
39
  v_file << " c.ssh.insert_key = false\n"
40
40
 
41
41
  hosts.each do |host|
42
+ host.name.tr!('_','-') # Rewrite Hostname with hyphens instead of underscores to get legal hostname
42
43
  host['ip'] ||= randip #use the existing ip, otherwise default to a random ip
43
44
  v_file << " c.vm.define '#{host.name}' do |v|\n"
44
45
  v_file << " v.vm.hostname = '#{host.name}'\n"
@@ -106,6 +106,18 @@ EOF
106
106
  expect( vagrantfile ).to match(/(ssh.forward_agent = true)/)
107
107
  end
108
108
 
109
+ it "can replace underscores in host.name with hypens" do
110
+ path = vagrant.instance_variable_get( :@vagrant_path )
111
+ allow( vagrant ).to receive( :randmac ).and_return( "0123456789" )
112
+
113
+ host = make_host( 'name-with_underscore', {} )
114
+ vagrant.make_vfile( [host,], options )
115
+
116
+ vagrantfile = File.read( File.expand_path( File.join( path, "Vagrantfile")))
117
+ expect( vagrantfile ).to match(/v.vm.hostname = .*name-with-underscore/)
118
+
119
+ end
120
+
109
121
  it "can make a Vagrantfile with synced_folder disabled" do
110
122
  path = vagrant.instance_variable_get( :@vagrant_path )
111
123
  allow( vagrant ).to receive( :randmac ).and_return( "0123456789" )
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: beaker-vagrant
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rishi Javia, Kevin Imber, Tony Vu
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-11-20 00:00:00.000000000 Z
11
+ date: 2018-01-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec