virtualbox 0.7.5 → 0.7.6
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.
- data/.gitignore +2 -1
- data/Gemfile +3 -12
- data/Rakefile +36 -4
- data/features/support/env.rb +0 -1
- data/lib/virtualbox/abstract_model/attributable.rb +1 -1
- data/lib/virtualbox/abstract_model/dirty.rb +2 -2
- data/lib/virtualbox/abstract_model.rb +1 -1
- data/lib/virtualbox/com/ffi/vboxxpcomc.rb +2 -2
- data/lib/virtualbox/com/interface/3.1.x/access_mode.rb +11 -0
- data/lib/virtualbox/com/interface/3.1.x/machine.rb +1 -1
- data/lib/virtualbox/com/interface/3.1.x/virtualbox.rb +1 -1
- data/lib/virtualbox/com/interface/3.2.x/access_mode.rb +11 -0
- data/lib/virtualbox/com/interface/3.2.x/machine.rb +1 -1
- data/lib/virtualbox/com/interface/3.2.x/virtualbox.rb +1 -1
- data/lib/virtualbox/ext/platform.rb +4 -0
- data/lib/virtualbox/lib.rb +2 -0
- data/lib/virtualbox/version.rb +2 -0
- data/test/test_helper.rb +1 -10
- data/test/virtualbox/abstract_model/attributable_test.rb +1 -1
- data/test/virtualbox/abstract_model/dirty_test.rb +2 -2
- data/test/virtualbox/abstract_model/interface_attributes_test.rb +1 -1
- data/test/virtualbox/abstract_model/relatable_test.rb +1 -1
- data/test/virtualbox/abstract_model/validatable_test.rb +2 -2
- data/test/virtualbox/abstract_model/version_matcher_test.rb +1 -1
- data/test/virtualbox/abstract_model_test.rb +2 -1
- data/test/virtualbox/appliance_test.rb +1 -1
- data/test/virtualbox/audio_adapter_test.rb +2 -2
- data/test/virtualbox/bios_test.rb +2 -2
- data/test/virtualbox/com/abstract_enum_test.rb +2 -2
- data/test/virtualbox/com/abstract_implementer_test.rb +1 -1
- data/test/virtualbox/com/abstract_interface_test.rb +1 -1
- data/test/virtualbox/com/ffi/interface_test.rb +2 -2
- data/test/virtualbox/com/ffi/util_test.rb +2 -2
- data/test/virtualbox/com/ffi_interface_test.rb +2 -2
- data/test/virtualbox/com/implementer/base_test.rb +1 -1
- data/test/virtualbox/com/implementer/ffi_test.rb +2 -2
- data/test/virtualbox/com/implementer/mscom_test.rb +5 -10
- data/test/virtualbox/com/mscom_interface_test.rb +2 -2
- data/test/virtualbox/com/util_test.rb +2 -2
- data/test/virtualbox/cpu_test.rb +2 -2
- data/test/virtualbox/dhcp_server_test.rb +1 -1
- data/test/virtualbox/dvd_test.rb +2 -2
- data/test/virtualbox/ext/byte_normalizer_test.rb +2 -2
- data/test/virtualbox/ext/platform_test.rb +2 -2
- data/test/virtualbox/ext/subclass_listing_test.rb +2 -2
- data/test/virtualbox/extra_data_test.rb +1 -1
- data/test/virtualbox/forwarded_port_test.rb +1 -1
- data/test/virtualbox/global_test.rb +2 -2
- data/test/virtualbox/hard_drive_test.rb +1 -1
- data/test/virtualbox/host_network_interface_test.rb +1 -1
- data/test/virtualbox/host_test.rb +1 -1
- data/test/virtualbox/hw_virtualization_test.rb +2 -2
- data/test/virtualbox/lib_test.rb +2 -2
- data/test/virtualbox/medium_attachment_test.rb +2 -2
- data/test/virtualbox/medium_test.rb +2 -2
- data/test/virtualbox/nat_engine_test.rb +1 -1
- data/test/virtualbox/nat_forwarded_port_test.rb +1 -1
- data/test/virtualbox/network_adapter_test.rb +1 -1
- data/test/virtualbox/proxies/collection_test.rb +1 -1
- data/test/virtualbox/shared_folder_test.rb +2 -1
- data/test/virtualbox/snapshot_test.rb +2 -2
- data/test/virtualbox/storage_controller_test.rb +2 -2
- data/test/virtualbox/system_properties_test.rb +2 -2
- data/test/virtualbox/usb_controller_test.rb +4 -3
- data/test/virtualbox/usb_device_filter_test.rb +1 -1
- data/test/virtualbox/version_test.rb +1 -1
- data/test/virtualbox/virtual_system_description_test.rb +2 -2
- data/test/virtualbox/vm_test.rb +2 -1
- data/test/virtualbox/vrdp_server_test.rb +2 -2
- data/test/virtualbox_test.rb +2 -2
- data/virtualbox.gemspec +17 -369
- metadata +53 -79
- data/VERSION +0 -1
- data/tasks/cucumber.task +0 -13
- data/tasks/jeweler.task +0 -21
- data/tasks/rcov.task +0 -15
- data/tasks/test.task +0 -10
- data/tasks/yard.task +0 -9
data/.gitignore
CHANGED
data/Gemfile
CHANGED
@@ -1,25 +1,16 @@
|
|
1
1
|
source "http://rubygems.org"
|
2
2
|
|
3
|
-
|
4
|
-
gem "ffi"
|
3
|
+
gemspec
|
5
4
|
|
6
5
|
# Gems required for development only.
|
7
6
|
group :development do
|
8
|
-
#
|
9
|
-
gem "jeweler"
|
7
|
+
# Docs
|
10
8
|
gem "yard"
|
11
9
|
|
12
10
|
# Unit tests
|
13
|
-
gem "
|
14
|
-
gem "mocha"
|
15
|
-
gem "rcov"
|
11
|
+
# gem "rcov"
|
16
12
|
|
17
13
|
# Integration tests
|
18
14
|
gem "cucumber", "~> 0.8.0"
|
19
|
-
gem "aruba", "~> 0.1.9"
|
20
15
|
gem "rspec"
|
21
|
-
|
22
|
-
# Generally good to have
|
23
|
-
gem "ruby-debug", ">= 0.10.3" if RUBY_VERSION < '1.9'
|
24
|
-
gem "ruby-debug19", ">= 0.11.6" if RUBY_VERSION >= '1.9'
|
25
16
|
end
|
data/Rakefile
CHANGED
@@ -1,5 +1,37 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
1
|
+
require "rubygems"
|
2
|
+
require "bundler/setup"
|
3
|
+
require "rake/testtask"
|
4
|
+
|
5
|
+
require "cucumber"
|
6
|
+
require "cucumber/rake/task"
|
7
|
+
require "yard"
|
8
|
+
Bundler::GemHelper.install_tasks
|
9
|
+
|
10
|
+
task :default => "test:units"
|
11
|
+
|
12
|
+
namespace :test do
|
13
|
+
Rake::TestTask.new(:units) do |t|
|
14
|
+
t.libs << "test"
|
15
|
+
t.pattern = 'test/**/*_test.rb'
|
16
|
+
end
|
17
|
+
|
18
|
+
Cucumber::Rake::Task.new(:integration) do |t|
|
19
|
+
t.cucumber_opts = "features --format pretty"
|
20
|
+
end
|
21
|
+
|
22
|
+
begin
|
23
|
+
require "rcov/rcovtask"
|
24
|
+
|
25
|
+
Rcov::RcovTask.new do |t|
|
26
|
+
t.libs << "test"
|
27
|
+
t.test_files = FileList["test/**/*_test.rb"]
|
28
|
+
t.output_dir = "test/coverage"
|
29
|
+
t.verbose = true
|
30
|
+
end
|
31
|
+
rescue LoadError; end
|
32
|
+
end
|
33
|
+
|
34
|
+
YARD::Rake::YardocTask.new do |t|
|
35
|
+
t.options = ['--main', 'Readme.md', '--markup', 'markdown']
|
36
|
+
t.options += ['--title', 'VirtualBox Ruby Library Documentation']
|
5
37
|
end
|
data/features/support/env.rb
CHANGED
@@ -153,7 +153,7 @@ module VirtualBox
|
|
153
153
|
# a custom populate key to use for {Attributable#populate_attributes}
|
154
154
|
def attribute(name, options = {})
|
155
155
|
name = name.to_sym
|
156
|
-
attributes[name] = @__attribute_scope
|
156
|
+
attributes[name] = defined?(@__attribute_scope) ? @__attribute_scope : {}
|
157
157
|
attributes[name].merge!(options)
|
158
158
|
|
159
159
|
# Create the method for reading this attribute
|
@@ -125,7 +125,7 @@ module VirtualBox
|
|
125
125
|
# Guarantees the dirty state will be the same before and after
|
126
126
|
# the method call, but not within the block itself.
|
127
127
|
def ignore_dirty(&block)
|
128
|
-
current_changes =
|
128
|
+
current_changes = changes.dup
|
129
129
|
yield self
|
130
130
|
@changed_attributes = current_changes
|
131
131
|
end
|
@@ -174,4 +174,4 @@ module VirtualBox
|
|
174
174
|
end
|
175
175
|
end
|
176
176
|
end
|
177
|
-
end
|
177
|
+
end
|
@@ -57,7 +57,7 @@ module VirtualBox
|
|
57
57
|
# is {HardDrive#save} which will create a new hard drive if it didn't
|
58
58
|
# previously exist, or save an old one if it did exist.
|
59
59
|
def new_record?
|
60
|
-
new_record! if @new_record.nil?
|
60
|
+
new_record! if !defined?(@new_record) || @new_record.nil?
|
61
61
|
@new_record
|
62
62
|
end
|
63
63
|
|
@@ -5,7 +5,7 @@ module VirtualBox
|
|
5
5
|
callback :pfnGetVersion, [], :uint
|
6
6
|
callback :pfnComInitialize, [:string, :pointer, :string, :pointer], :void
|
7
7
|
callback :pfnComUninitialize, [], :void
|
8
|
-
callback :pfnComUnallocMem, [:
|
8
|
+
callback :pfnComUnallocMem, [:pointer], :void
|
9
9
|
callback :pfnUtf16Free, [:pointer], :void
|
10
10
|
callback :pfnUtf8Free, [:string], :void
|
11
11
|
callback :pfnUtf16ToUtf8, [:pointer, :pointer], :int
|
@@ -28,4 +28,4 @@ module VirtualBox
|
|
28
28
|
end
|
29
29
|
end
|
30
30
|
end
|
31
|
-
end
|
31
|
+
end
|
@@ -60,7 +60,7 @@ module VirtualBox
|
|
60
60
|
function :get_medium_attachments_of_controller, [:MediumAttachments], [WSTRING]
|
61
61
|
function :get_medium_attachment, :MediumAttachment, [WSTRING, T_INT32, T_INT32]
|
62
62
|
function :get_network_adapter, :NetworkAdapter, [T_UINT32]
|
63
|
-
function :add_storage_controller, :StorageController, [WSTRING,
|
63
|
+
function :add_storage_controller, :StorageController, [WSTRING, :StorageBus]
|
64
64
|
function :get_storage_controller_by_name, :StorageController, [WSTRING]
|
65
65
|
function :get_storage_controller_by_instance, :StorageController, [T_UINT32]
|
66
66
|
function :remove_storage_controller, nil, [WSTRING]
|
@@ -31,7 +31,7 @@ module VirtualBox
|
|
31
31
|
function :unregister_machine, :Machine, [WSTRING]
|
32
32
|
function :create_appliance, :Appliance, []
|
33
33
|
function :create_hard_disk, :Medium, [WSTRING, WSTRING]
|
34
|
-
function :open_hard_disk, :Medium, [WSTRING,
|
34
|
+
function :open_hard_disk, :Medium, [WSTRING, :AccessMode, T_BOOL, WSTRING, T_BOOL, WSTRING]
|
35
35
|
function :get_hard_disk, :Medium, [WSTRING]
|
36
36
|
function :find_hard_disk, :Medium, [WSTRING]
|
37
37
|
function :open_dvd_image, :Medium, [WSTRING, WSTRING]
|
@@ -68,7 +68,7 @@ module VirtualBox
|
|
68
68
|
function :get_medium_attachments_of_controller, [:MediumAttachments], [WSTRING]
|
69
69
|
function :get_medium_attachment, :MediumAttachment, [WSTRING, T_INT32, T_INT32]
|
70
70
|
function :get_network_adapter, :NetworkAdapter, [T_UINT32]
|
71
|
-
function :add_storage_controller, :StorageController, [WSTRING,
|
71
|
+
function :add_storage_controller, :StorageController, [WSTRING, :StorageBus]
|
72
72
|
function :get_storage_controller_by_name, :StorageController, [WSTRING]
|
73
73
|
function :get_storage_controller_by_instance, :StorageController, [T_UINT32]
|
74
74
|
function :remove_storage_controller, nil, [WSTRING]
|
@@ -31,7 +31,7 @@ module VirtualBox
|
|
31
31
|
function :unregister_machine, :Machine, [WSTRING]
|
32
32
|
function :create_appliance, :Appliance, []
|
33
33
|
function :create_hard_disk, :Medium, [WSTRING, WSTRING]
|
34
|
-
function :open_hard_disk, :Medium, [WSTRING,
|
34
|
+
function :open_hard_disk, :Medium, [WSTRING, :AccessMode, T_BOOL, WSTRING, T_BOOL, WSTRING]
|
35
35
|
function :get_hard_disk, :Medium, [WSTRING]
|
36
36
|
function :find_hard_disk, :Medium, [WSTRING]
|
37
37
|
function :open_dvd_image, :Medium, [WSTRING, WSTRING]
|
data/lib/virtualbox/lib.rb
CHANGED
@@ -57,6 +57,8 @@ module VirtualBox
|
|
57
57
|
@@lib_path = ["/Applications/VirtualBox.app/Contents/MacOS/VBoxXPCOMC.dylib"]
|
58
58
|
elsif Platform.linux?
|
59
59
|
@@lib_path = ["/opt/VirtualBox/VBoxXPCOMC.so", "/usr/lib/virtualbox/VBoxXPCOMC.so"]
|
60
|
+
elsif Platform.solaris?
|
61
|
+
@@lib_path = ["/opt/VirtualBox/amd64/VBoxXPCOMC.so", "/opt/VirtualBox/i386/VBoxXPCOMC.so"]
|
60
62
|
elsif Platform.windows?
|
61
63
|
@@lib_path = "Unknown"
|
62
64
|
else
|
data/lib/virtualbox/version.rb
CHANGED
data/test/test_helper.rb
CHANGED
@@ -1,10 +1,3 @@
|
|
1
|
-
begin
|
2
|
-
require File.expand_path('../../.bundle/environment', __FILE__)
|
3
|
-
rescue LoadError
|
4
|
-
# Fallback on doing the resolve at runtime.
|
5
|
-
require "rubygems"
|
6
|
-
end
|
7
|
-
|
8
1
|
# ruby-debug, not necessary, but useful if we have it
|
9
2
|
begin
|
10
3
|
require 'ruby-debug'
|
@@ -12,9 +5,7 @@ rescue LoadError; end
|
|
12
5
|
|
13
6
|
require 'contest'
|
14
7
|
require 'mocha'
|
15
|
-
|
16
|
-
# The actual library
|
17
|
-
require File.join(File.dirname(__FILE__), '..', 'lib', 'virtualbox')
|
8
|
+
require 'virtualbox'
|
18
9
|
|
19
10
|
# Data
|
20
11
|
class Test::Unit::TestCase
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class DirtyTest < Test::Unit::TestCase
|
4
4
|
class DirtyModel
|
@@ -80,4 +80,4 @@ class DirtyTest < Test::Unit::TestCase
|
|
80
80
|
assert_raises(NoMethodError) { @model.foobarbaz }
|
81
81
|
end
|
82
82
|
end
|
83
|
-
end
|
83
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class ValidatableTest < Test::Unit::TestCase
|
4
4
|
class ValidatableModel
|
@@ -305,4 +305,4 @@ class ValidatableTest < Test::Unit::TestCase
|
|
305
305
|
end
|
306
306
|
end
|
307
307
|
end
|
308
|
-
end
|
308
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class AbstractModelTest < Test::Unit::TestCase
|
4
4
|
class Foo
|
@@ -406,6 +406,7 @@ class AbstractModelTest < Test::Unit::TestCase
|
|
406
406
|
|
407
407
|
context "saving all changed interface attributes" do
|
408
408
|
setup do
|
409
|
+
@interface = mock("interface")
|
409
410
|
@changes = [[:a, []], [:b, []], [:c, []]]
|
410
411
|
@model.stubs(:changes).returns(@changes)
|
411
412
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class AudioAdapterTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -80,4 +80,4 @@ class AudioAdapterTest < Test::Unit::TestCase
|
|
80
80
|
end
|
81
81
|
end
|
82
82
|
end
|
83
|
-
end
|
83
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class BIOSTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -80,4 +80,4 @@ class BIOSTest < Test::Unit::TestCase
|
|
80
80
|
end
|
81
81
|
end
|
82
82
|
end
|
83
|
-
end
|
83
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMAbstractEnumTest < Test::Unit::TestCase
|
4
4
|
context "setting up the map" do
|
@@ -46,4 +46,4 @@ class COMAbstractEnumTest < Test::Unit::TestCase
|
|
46
46
|
end
|
47
47
|
end
|
48
48
|
end
|
49
|
-
end
|
49
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMFFIInterfaceTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -246,4 +246,4 @@ class COMFFIInterfaceTest < Test::Unit::TestCase
|
|
246
246
|
assert_equal vtbl, instance.vtbl
|
247
247
|
end
|
248
248
|
end
|
249
|
-
end
|
249
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMFFIUtilTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -105,4 +105,4 @@ class COMFFIUtilTest < Test::Unit::TestCase
|
|
105
105
|
end
|
106
106
|
end
|
107
107
|
end
|
108
|
-
end
|
108
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMFFIInterfaceBaseTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -39,4 +39,4 @@ class COMFFIInterfaceBaseTest < Test::Unit::TestCase
|
|
39
39
|
context "initializing com interface" do
|
40
40
|
# TODO
|
41
41
|
end
|
42
|
-
end
|
42
|
+
end
|
@@ -1,13 +1,13 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMImplementerFFITest < Test::Unit::TestCase
|
4
4
|
setup do
|
5
5
|
@klass = VirtualBox::COM::Implementer::FFI
|
6
|
+
@interface = mock("interface")
|
6
7
|
end
|
7
8
|
|
8
9
|
context "initializing" do
|
9
10
|
setup do
|
10
|
-
@interface = mock("interface")
|
11
11
|
@interface.stubs(:class).returns(VirtualBox::COM::Util.versioned_interface(:Session))
|
12
12
|
|
13
13
|
@ffi = mock("ffi")
|
@@ -1,17 +1,14 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMImplementerMSCOMTest < Test::Unit::TestCase
|
4
4
|
setup do
|
5
5
|
@klass = VirtualBox::COM::Implementer::MSCOM
|
6
|
+
@interface = mock("interface")
|
7
|
+
@lib = mock("lib")
|
8
|
+
@object = mock("object")
|
6
9
|
end
|
7
10
|
|
8
11
|
context "initializing" do
|
9
|
-
setup do
|
10
|
-
@interface = mock("interface")
|
11
|
-
@lib = mock("lib")
|
12
|
-
@object = mock("object")
|
13
|
-
end
|
14
|
-
|
15
12
|
should "make the lib base and object accessible" do
|
16
13
|
instance = @klass.new(@interface, @lib, @object)
|
17
14
|
assert_equal @lib, instance.lib
|
@@ -21,8 +18,6 @@ class COMImplementerMSCOMTest < Test::Unit::TestCase
|
|
21
18
|
|
22
19
|
context "with an instance" do
|
23
20
|
setup do
|
24
|
-
@lib = mock("lib")
|
25
|
-
@object = mock("object")
|
26
21
|
@instance = @klass.new(@interface, @lib, @object)
|
27
22
|
end
|
28
23
|
|
@@ -249,4 +244,4 @@ class COMImplementerMSCOMTest < Test::Unit::TestCase
|
|
249
244
|
end
|
250
245
|
end
|
251
246
|
end
|
252
|
-
end
|
247
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMMSCOMInterfaceBaseTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -14,4 +14,4 @@ class COMMSCOMInterfaceBaseTest < Test::Unit::TestCase
|
|
14
14
|
context "initializing mscom interface" do
|
15
15
|
# TODO
|
16
16
|
end
|
17
|
-
end
|
17
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class COMUtilTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -14,4 +14,4 @@ class COMUtilTest < Test::Unit::TestCase
|
|
14
14
|
assert !@klass.interface?(:IDontExist)
|
15
15
|
end
|
16
16
|
end
|
17
|
-
end
|
17
|
+
end
|
data/test/virtualbox/cpu_test.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class CPUTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -100,4 +100,4 @@ class CPUTest < Test::Unit::TestCase
|
|
100
100
|
end
|
101
101
|
end
|
102
102
|
end
|
103
|
-
end
|
103
|
+
end
|
data/test/virtualbox/dvd_test.rb
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class DVDTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -25,4 +25,4 @@ class DVDTest < Test::Unit::TestCase
|
|
25
25
|
assert result.is_a?(Array)
|
26
26
|
end
|
27
27
|
end
|
28
|
-
end
|
28
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
require 'virtualbox/ext/byte_normalizer'
|
3
3
|
|
4
4
|
class ByteNormalizerTest < Test::Unit::TestCase
|
@@ -31,4 +31,4 @@ class ByteNormalizerTest < Test::Unit::TestCase
|
|
31
31
|
assert_equal out, @instance.bytes_to_megabytes(input)
|
32
32
|
end
|
33
33
|
end
|
34
|
-
end
|
34
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
require 'virtualbox/ext/platform'
|
3
3
|
|
4
4
|
class PlatformTest < Test::Unit::TestCase
|
@@ -47,4 +47,4 @@ class PlatformTest < Test::Unit::TestCase
|
|
47
47
|
end
|
48
48
|
end
|
49
49
|
end
|
50
|
-
end
|
50
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../../test_helper", __FILE__)
|
2
2
|
require 'virtualbox/ext/subclass_listing'
|
3
3
|
|
4
4
|
class SubclassListingTest < Test::Unit::TestCase
|
@@ -22,4 +22,4 @@ class SubclassListingTest < Test::Unit::TestCase
|
|
22
22
|
should "list direct subclasses if flag is set" do
|
23
23
|
assert_equal [B, D], A.subclasses(true).sort_by { |c| c.name }
|
24
24
|
end
|
25
|
-
end
|
25
|
+
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
require File.
|
1
|
+
require File.expand_path("../../test_helper", __FILE__)
|
2
2
|
|
3
3
|
class GlobalTest < Test::Unit::TestCase
|
4
4
|
setup do
|
@@ -43,4 +43,4 @@ class GlobalTest < Test::Unit::TestCase
|
|
43
43
|
assert_equal @lib, @instance.lib
|
44
44
|
end
|
45
45
|
end
|
46
|
-
end
|
46
|
+
end
|