fog-libvirt 0.5.0 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +1 -1
  3. data/fog-libvirt.gemspec +3 -3
  4. data/lib/fog/bin/libvirt.rb +1 -1
  5. data/lib/fog/libvirt.rb +1 -3
  6. data/lib/fog/libvirt/compute.rb +12 -11
  7. data/lib/fog/libvirt/models/compute/README.md +16 -0
  8. data/lib/fog/libvirt/models/compute/interface.rb +2 -2
  9. data/lib/fog/libvirt/models/compute/interfaces.rb +3 -3
  10. data/lib/fog/libvirt/models/compute/network.rb +3 -3
  11. data/lib/fog/libvirt/models/compute/networks.rb +3 -3
  12. data/lib/fog/libvirt/models/compute/nic.rb +2 -2
  13. data/lib/fog/libvirt/models/compute/nics.rb +3 -3
  14. data/lib/fog/libvirt/models/compute/node.rb +2 -2
  15. data/lib/fog/libvirt/models/compute/nodes.rb +3 -3
  16. data/lib/fog/libvirt/models/compute/pool.rb +2 -2
  17. data/lib/fog/libvirt/models/compute/pools.rb +3 -3
  18. data/lib/fog/libvirt/models/compute/server.rb +23 -8
  19. data/lib/fog/libvirt/models/compute/servers.rb +3 -3
  20. data/lib/fog/libvirt/models/compute/templates/server.xml.erb +65 -0
  21. data/lib/fog/libvirt/models/compute/templates/volume.xml.erb +8 -4
  22. data/lib/fog/libvirt/models/compute/util/uri.rb +2 -2
  23. data/lib/fog/libvirt/models/compute/util/util.rb +2 -2
  24. data/lib/fog/libvirt/models/compute/volume.rb +11 -9
  25. data/lib/fog/libvirt/models/compute/volumes.rb +3 -3
  26. data/lib/fog/libvirt/requests/compute/clone_volume.rb +3 -3
  27. data/lib/fog/libvirt/requests/compute/create_domain.rb +2 -2
  28. data/lib/fog/libvirt/requests/compute/create_volume.rb +2 -2
  29. data/lib/fog/libvirt/requests/compute/define_domain.rb +2 -2
  30. data/lib/fog/libvirt/requests/compute/define_pool.rb +2 -2
  31. data/lib/fog/libvirt/requests/compute/destroy_interface.rb +2 -2
  32. data/lib/fog/libvirt/requests/compute/destroy_network.rb +2 -2
  33. data/lib/fog/libvirt/requests/compute/dhcp_leases.rb +2 -2
  34. data/lib/fog/libvirt/requests/compute/get_node_info.rb +2 -2
  35. data/lib/fog/libvirt/requests/compute/libversion.rb +2 -2
  36. data/lib/fog/libvirt/requests/compute/list_domains.rb +9 -3
  37. data/lib/fog/libvirt/requests/compute/list_interfaces.rb +2 -2
  38. data/lib/fog/libvirt/requests/compute/list_networks.rb +11 -3
  39. data/lib/fog/libvirt/requests/compute/list_pool_volumes.rb +2 -2
  40. data/lib/fog/libvirt/requests/compute/list_pools.rb +2 -2
  41. data/lib/fog/libvirt/requests/compute/list_volumes.rb +16 -8
  42. data/lib/fog/libvirt/requests/compute/pool_action.rb +2 -2
  43. data/lib/fog/libvirt/requests/compute/update_autostart.rb +18 -0
  44. data/lib/fog/libvirt/requests/compute/update_display.rb +2 -2
  45. data/lib/fog/libvirt/requests/compute/upload_volume.rb +2 -2
  46. data/lib/fog/libvirt/requests/compute/vm_action.rb +2 -2
  47. data/lib/fog/libvirt/requests/compute/volume_action.rb +2 -2
  48. data/lib/fog/libvirt/version.rb +1 -1
  49. data/minitests/server/server_test.rb +1 -1
  50. data/minitests/server/user_data_iso_test.rb +8 -11
  51. data/minitests/test_helper.rb +1 -1
  52. data/tests/helper.rb +1 -1
  53. data/tests/helpers/formats_helper.rb +58 -56
  54. data/tests/helpers/formats_helper_tests.rb +22 -25
  55. data/tests/helpers/mock_helper.rb +1 -1
  56. data/tests/helpers/succeeds_helper.rb +2 -2
  57. data/tests/libvirt/compute_tests.rb +2 -1
  58. data/tests/libvirt/models/compute/interface_tests.rb +1 -1
  59. data/tests/libvirt/models/compute/interfaces_tests.rb +1 -1
  60. data/tests/libvirt/models/compute/network_tests.rb +1 -1
  61. data/tests/libvirt/models/compute/networks_tests.rb +1 -1
  62. data/tests/libvirt/models/compute/nic_tests.rb +1 -1
  63. data/tests/libvirt/models/compute/pool_tests.rb +1 -1
  64. data/tests/libvirt/models/compute/pools_tests.rb +1 -1
  65. data/tests/libvirt/models/compute/server_tests.rb +4 -1
  66. data/tests/libvirt/models/compute/servers_tests.rb +1 -1
  67. data/tests/libvirt/models/compute/volume_tests.rb +1 -1
  68. data/tests/libvirt/models/compute/volumes_tests.rb +2 -1
  69. data/tests/libvirt/requests/compute/update_autostart_tests.rb +12 -0
  70. metadata +12 -16
@@ -4,7 +4,7 @@ Shindo.tests('Fog::Compute[:libvirt] | servers collection', ['libvirt']) do
4
4
 
5
5
  tests('The servers collection') do
6
6
  test('should not be empty') { not servers.empty? }
7
- test('should be a kind of Fog::Compute::Libvirt::Servers') { servers.kind_of? Fog::Compute::Libvirt::Servers }
7
+ test('should be a kind of Fog::Libvirt::Compute::Servers') { servers.kind_of? Fog::Libvirt::Compute::Servers }
8
8
  tests('should be able to reload itself').succeeds { servers.reload }
9
9
  tests('should be able to get a model') do
10
10
  tests('by instance uuid').succeeds { servers.get servers.first.id }
@@ -24,7 +24,7 @@ Shindo.tests('Fog::Compute[:libvirt] | volume model', ['libvirt']) do
24
24
  end
25
25
  end
26
26
  end
27
- test('be a kind of Fog::Compute::Libvirt::Volume') { volume.kind_of? Fog::Compute::Libvirt::Volume }
27
+ test('be a kind of Fog::Libvirt::Compute::Volume') { volume.kind_of? Fog::Libvirt::Compute::Volume }
28
28
  end
29
29
 
30
30
  tests('Cloning volumes should') do
@@ -4,11 +4,12 @@ Shindo.tests('Fog::Compute[:libvirt] | volumes collection', ['libvirt']) do
4
4
 
5
5
  tests('The volumes collection') do
6
6
  test('should not be empty') { not volumes.empty? }
7
- test('should be a kind of Fog::Compute::Libvirt::Volumes') { volumes.kind_of? Fog::Compute::Libvirt::Volumes }
7
+ test('should be a kind of Fog::Libvirt::Compute::Volumes') { volumes.kind_of? Fog::Libvirt::Compute::Volumes }
8
8
  tests('should be able to reload itself').succeeds { volumes.reload }
9
9
  tests('should be able to get a model') do
10
10
  tests('by instance uuid').succeeds { volumes.get volumes.first.id }
11
11
  end
12
+ test('filtered should be empty') { volumes.all(:name => "does-not-exist").empty? }
12
13
  end
13
14
 
14
15
  end
@@ -0,0 +1,12 @@
1
+ Shindo.tests('Fog::Compute[:libvirt] | update_autostart request', ['libvirt']) do
2
+
3
+ servers = Fog::Compute[:libvirt].servers
4
+
5
+ tests('The response should') do
6
+ test('should not be empty') { not servers.empty? }
7
+ server = servers.first
8
+ tests('should be false').succeeds { server.autostart == false }
9
+ server.update_autostart(true)
10
+ end
11
+
12
+ end
metadata CHANGED
@@ -1,22 +1,19 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fog-libvirt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - geemus (Wesley Beary)
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-27 00:00:00.000000000 Z
11
+ date: 2021-07-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fog-core
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '1.27'
20
17
  - - ">="
21
18
  - !ruby/object:Gem::Version
22
19
  version: 1.27.4
@@ -24,9 +21,6 @@ dependencies:
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
- - - "~>"
28
- - !ruby/object:Gem::Version
29
- version: '1.27'
30
24
  - - ">="
31
25
  - !ruby/object:Gem::Version
32
26
  version: 1.27.4
@@ -218,14 +212,14 @@ dependencies:
218
212
  requirements:
219
213
  - - "~>"
220
214
  - !ruby/object:Gem::Version
221
- version: 1.1.0
215
+ version: 1.13.0
222
216
  type: :development
223
217
  prerelease: false
224
218
  version_requirements: !ruby/object:Gem::Requirement
225
219
  requirements:
226
220
  - - "~>"
227
221
  - !ruby/object:Gem::Version
228
- version: 1.1.0
222
+ version: 1.13.0
229
223
  description: This library can be used as a module for 'fog' or as standalone libvirt
230
224
  provider.
231
225
  email: geemus@gmail.com
@@ -282,6 +276,7 @@ files:
282
276
  - lib/fog/libvirt/requests/compute/list_volumes.rb
283
277
  - lib/fog/libvirt/requests/compute/mock_files/domain.xml
284
278
  - lib/fog/libvirt/requests/compute/pool_action.rb
279
+ - lib/fog/libvirt/requests/compute/update_autostart.rb
285
280
  - lib/fog/libvirt/requests/compute/update_display.rb
286
281
  - lib/fog/libvirt/requests/compute/upload_volume.rb
287
282
  - lib/fog/libvirt/requests/compute/vm_action.rb
@@ -311,12 +306,13 @@ files:
311
306
  - tests/libvirt/requests/compute/create_domain_tests.rb
312
307
  - tests/libvirt/requests/compute/define_domain_tests.rb
313
308
  - tests/libvirt/requests/compute/dhcp_leases_tests.rb
309
+ - tests/libvirt/requests/compute/update_autostart_tests.rb
314
310
  - tests/libvirt/requests/compute/update_display.rb
315
311
  homepage: http://github.com/fog/fog-libvirt
316
312
  licenses:
317
313
  - MIT
318
314
  metadata: {}
319
- post_install_message:
315
+ post_install_message:
320
316
  rdoc_options:
321
317
  - "--charset=UTF-8"
322
318
  require_paths:
@@ -325,16 +321,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
325
321
  requirements:
326
322
  - - ">="
327
323
  - !ruby/object:Gem::Version
328
- version: 2.0.0
324
+ version: 2.5.0
329
325
  required_rubygems_version: !ruby/object:Gem::Requirement
330
326
  requirements:
331
327
  - - ">="
332
328
  - !ruby/object:Gem::Version
333
329
  version: '0'
334
330
  requirements: []
335
- rubyforge_project:
336
- rubygems_version: 2.6.12
337
- signing_key:
331
+ rubygems_version: 3.2.15
332
+ signing_key:
338
333
  specification_version: 2
339
334
  summary: Module for the 'fog' gem to support libvirt
340
335
  test_files:
@@ -359,4 +354,5 @@ test_files:
359
354
  - tests/libvirt/requests/compute/create_domain_tests.rb
360
355
  - tests/libvirt/requests/compute/define_domain_tests.rb
361
356
  - tests/libvirt/requests/compute/dhcp_leases_tests.rb
357
+ - tests/libvirt/requests/compute/update_autostart_tests.rb
362
358
  - tests/libvirt/requests/compute/update_display.rb