windows-pr 1.2.3 → 1.2.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGES +5 -0
- data/Rakefile +3 -3
- data/test/helper.rb +13 -0
- data/test/tc_clipboard.rb +2 -2
- data/test/tc_com.rb +2 -2
- data/test/tc_com_automation.rb +2 -2
- data/test/tc_console.rb +2 -2
- data/test/tc_debug.rb +3 -3
- data/test/tc_device_io.rb +2 -2
- data/test/tc_directory.rb +2 -2
- data/test/tc_error.rb +7 -7
- data/test/tc_eventlog.rb +5 -5
- data/test/tc_file.rb +18 -18
- data/test/tc_file_mapping.rb +7 -7
- data/test/tc_filesystem.rb +6 -6
- data/test/tc_gdi_bitmap.rb +2 -2
- data/test/tc_gdi_metafile.rb +2 -2
- data/test/tc_handle.rb +5 -6
- data/test/tc_library.rb +3 -3
- data/test/tc_limits.rb +4 -5
- data/test/tc_mailslot.rb +2 -2
- data/test/tc_memory.rb +2 -2
- data/test/tc_msvcrt_buffer.rb +2 -2
- data/test/tc_msvcrt_directory.rb +7 -7
- data/test/tc_msvcrt_file.rb +5 -5
- data/test/tc_msvcrt_io.rb +5 -5
- data/test/tc_msvcrt_string.rb +2 -2
- data/test/tc_msvcrt_time.rb +3 -3
- data/test/tc_national.rb +5 -5
- data/test/tc_network_management.rb +5 -5
- data/test/tc_network_snmp.rb +4 -4
- data/test/tc_network_winsock.rb +4 -4
- data/test/tc_nio.rb +4 -4
- data/test/tc_ntfs_winternl.rb +3 -3
- data/test/tc_path.rb +2 -2
- data/test/tc_pipe.rb +5 -6
- data/test/tc_process.rb +2 -2
- data/test/tc_registry.rb +2 -2
- data/test/tc_security.rb +2 -2
- data/test/tc_security_authentication.rb +2 -2
- data/test/tc_security_sspi.rb +2 -2
- data/test/tc_service.rb +4 -4
- data/test/tc_shell.rb +4 -4
- data/test/tc_socket.rb +15 -5
- data/test/tc_sound.rb +4 -4
- data/test/tc_synchronize.rb +5 -5
- data/test/tc_system_info.rb +3 -3
- data/test/tc_thread.rb +2 -2
- data/test/tc_time.rb +4 -4
- data/test/tc_tool_helper.rb +2 -2
- data/test/tc_unicode.rb +8 -8
- data/test/tc_volume.rb +2 -2
- data/test/tc_window.rb +4 -4
- data/test/tc_window_classes.rb +4 -4
- data/test/tc_window_dialog.rb +4 -4
- data/test/tc_window_menu.rb +4 -4
- data/test/tc_window_message.rb +4 -4
- data/test/tc_window_properties.rb +3 -3
- data/test/tc_window_timer.rb +3 -3
- data/test/tc_wsa.rb +2 -2
- data/windows-pr.gemspec +1 -3
- metadata +13 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3ba22094903e6dc30021b290ac0aac86eeaef2cf
|
4
|
+
data.tar.gz: 51da5343cf128be4c95f4c75405bc7c08f1df734
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 01686ab8e05e52a1e259676159de1f0d76e189b36af3e751f4807020dd20c5ae9184e0ce731df33adef8a42696a289a0da20d6ee7acff10e2dde7b19260ea930
|
7
|
+
data.tar.gz: 6ea80c4d03b49d35454a505d7585728577c91c0439f1a19352a48f4fc80db9c65797e91b63bba721efb009310657e3dff90a2b7f0ca9c8c6c47ebb8da27ce157
|
data/CHANGES
CHANGED
@@ -1,3 +1,8 @@
|
|
1
|
+
= 1.2.4 - 18-Oct-2014
|
2
|
+
* Replaced test-unit with minitest for the test suite. This necessitated the
|
3
|
+
addition of a test helper file for compatibility.
|
4
|
+
* Fix for the Windows::Socket tests.
|
5
|
+
|
1
6
|
= 1.2.3 - 19-Feb-2014
|
2
7
|
* Updated the get_last_error method to better handle encoding issues. Thanks
|
3
8
|
go to dalang for the spot.
|
data/Rakefile
CHANGED
@@ -6,7 +6,7 @@ CLEAN.include("**/*.gem", "**/*.rbc")
|
|
6
6
|
|
7
7
|
namespace 'gem' do
|
8
8
|
desc 'Build the windows-pr gem'
|
9
|
-
task :create do
|
9
|
+
task :create => [:clean] do
|
10
10
|
spec = eval(IO.read('windows-pr.gemspec'))
|
11
11
|
if Gem::VERSION < "2.0"
|
12
12
|
Gem::Builder.new(spec).build
|
@@ -19,14 +19,14 @@ namespace 'gem' do
|
|
19
19
|
desc 'Install the windows-pr gem'
|
20
20
|
task :install => [:create] do
|
21
21
|
file = Dir["*.gem"].first
|
22
|
-
sh "gem install #{file}"
|
22
|
+
sh "gem install -l #{file}"
|
23
23
|
end
|
24
24
|
end
|
25
25
|
|
26
26
|
namespace 'test' do
|
27
27
|
Rake::TestTask.new('all') do |t|
|
28
28
|
t.warning = true
|
29
|
-
t.test_files = FileList['test/tc*']
|
29
|
+
t.test_files = FileList['test/helper.rb', 'test/tc*']
|
30
30
|
end
|
31
31
|
|
32
32
|
# Dynamically generate individual test tasks.
|
data/test/helper.rb
ADDED
data/test/tc_clipboard.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::Clipboard module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/clipboard'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
|
-
class TC_Windows_Clipboard <
|
9
|
+
class TC_Windows_Clipboard < MiniTest::Unit::TestCase
|
10
10
|
include Windows::Clipboard
|
11
11
|
|
12
12
|
def test_methods
|
data/test/tc_com.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::COM module.
|
5
5
|
#####################################################################
|
6
6
|
require "windows/com"
|
7
|
-
require "
|
7
|
+
require "minitest/autorun"
|
8
8
|
|
9
|
-
class TC_Windows_COM <
|
9
|
+
class TC_Windows_COM < MiniTest::Unit::TestCase
|
10
10
|
include Windows::COM
|
11
11
|
|
12
12
|
def test_method_constants
|
data/test/tc_com_automation.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::COM::Automation module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/com/automation'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
|
-
class TC_Windows_COM_Automation <
|
9
|
+
class TC_Windows_COM_Automation < MiniTest::Unit::TestCase
|
10
10
|
include Windows::COM::Automation
|
11
11
|
|
12
12
|
def test_method_constants
|
data/test/tc_console.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::Console module.
|
5
5
|
######################################################################
|
6
6
|
require 'windows/console'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
|
-
class TC_Windows_Console <
|
9
|
+
class TC_Windows_Console < MiniTest::Unit::TestCase
|
10
10
|
include Windows::Console
|
11
11
|
|
12
12
|
def setup
|
data/test/tc_debug.rb
CHANGED
@@ -4,18 +4,18 @@
|
|
4
4
|
# Test case for the Windows::Debug module.
|
5
5
|
#####################################################################
|
6
6
|
require "windows/debug"
|
7
|
-
require "
|
7
|
+
require "minitest/autorun"
|
8
8
|
|
9
9
|
class DebugFoo
|
10
10
|
include Windows::Debug
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_Debug <
|
13
|
+
class TC_Windows_Debug < MiniTest::Unit::TestCase
|
14
14
|
def setup
|
15
15
|
@foo = DebugFoo.new
|
16
16
|
@ver = `ver`.chomp
|
17
17
|
end
|
18
|
-
|
18
|
+
|
19
19
|
def test_method_constants
|
20
20
|
assert_not_nil(DebugFoo::ContinueDebugEvent)
|
21
21
|
assert_not_nil(DebugFoo::DebugActiveProcess)
|
data/test/tc_device_io.rb
CHANGED
@@ -4,13 +4,13 @@
|
|
4
4
|
# Test case for the Windows::DeviceIO module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/device_io'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class DeviceIOFoo
|
10
10
|
include Windows::DeviceIO
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_DeviceIO <
|
13
|
+
class TC_Windows_DeviceIO < MiniTest::Unit::TestCase
|
14
14
|
def setup
|
15
15
|
@foo = DeviceIOFoo.new
|
16
16
|
end
|
data/test/tc_directory.rb
CHANGED
@@ -4,13 +4,13 @@
|
|
4
4
|
# Test case for the Windows::Directory module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/directory'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class DirectoryFoo
|
10
10
|
include Windows::Directory
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_Directory <
|
13
|
+
class TC_Windows_Directory < MiniTest::Unit::TestCase
|
14
14
|
def setup
|
15
15
|
@foo = DirectoryFoo.new
|
16
16
|
end
|
data/test/tc_error.rb
CHANGED
@@ -4,25 +4,25 @@
|
|
4
4
|
# Test case for the Windows::Error module.
|
5
5
|
#####################################################################
|
6
6
|
require "windows/error"
|
7
|
-
require "
|
7
|
+
require "minitest/autorun"
|
8
8
|
|
9
|
-
class TC_Windows_Error <
|
9
|
+
class TC_Windows_Error < MiniTest::Unit::TestCase
|
10
10
|
include Windows::Error
|
11
|
-
|
11
|
+
|
12
12
|
def test_numeric_constants
|
13
13
|
assert_equal(0x00000100, FORMAT_MESSAGE_ALLOCATE_BUFFER)
|
14
14
|
assert_equal(0x00000200, FORMAT_MESSAGE_IGNORE_INSERTS)
|
15
15
|
assert_equal(0x00000400, FORMAT_MESSAGE_FROM_STRING)
|
16
16
|
assert_equal(0x00000800, FORMAT_MESSAGE_FROM_HMODULE)
|
17
17
|
assert_equal(0x00001000, FORMAT_MESSAGE_FROM_SYSTEM)
|
18
|
-
assert_equal(0x00002000, FORMAT_MESSAGE_ARGUMENT_ARRAY)
|
19
|
-
assert_equal(0x000000FF, FORMAT_MESSAGE_MAX_WIDTH_MASK)
|
18
|
+
assert_equal(0x00002000, FORMAT_MESSAGE_ARGUMENT_ARRAY)
|
19
|
+
assert_equal(0x000000FF, FORMAT_MESSAGE_MAX_WIDTH_MASK)
|
20
20
|
assert_equal(0x0001, SEM_FAILCRITICALERRORS)
|
21
21
|
assert_equal(0x0004, SEM_NOALIGNMENTFAULTEXCEPT)
|
22
22
|
assert_equal(0x0002, SEM_NOGPFAULTERRORBOX)
|
23
23
|
assert_equal(0x8000, SEM_NOOPENFILEERRORBOX)
|
24
24
|
end
|
25
|
-
|
25
|
+
|
26
26
|
def test_method_constants
|
27
27
|
assert_not_nil(GetLastError)
|
28
28
|
assert_not_nil(SetLastError)
|
@@ -30,7 +30,7 @@ class TC_Windows_Error < Test::Unit::TestCase
|
|
30
30
|
assert_not_nil(SetErrorMode)
|
31
31
|
assert_not_nil(FormatMessage)
|
32
32
|
end
|
33
|
-
|
33
|
+
|
34
34
|
def test_get_last_error
|
35
35
|
assert_nothing_raised{ get_last_error }
|
36
36
|
assert_kind_of(String, get_last_error)
|
data/test/tc_eventlog.rb
CHANGED
@@ -4,17 +4,17 @@
|
|
4
4
|
# Test case for the Windows::EventLog module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/eventlog'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class EventLogFoo
|
10
10
|
include Windows::EventLog
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_EventLog <
|
13
|
+
class TC_Windows_EventLog < MiniTest::Unit::TestCase
|
14
14
|
def setup
|
15
15
|
@foo = EventLogFoo.new
|
16
16
|
end
|
17
|
-
|
17
|
+
|
18
18
|
def test_numeric_constants
|
19
19
|
assert_equal(1, EventLogFoo::EVENTLOG_SEQUENTIAL_READ)
|
20
20
|
assert_equal(2, EventLogFoo::EVENTLOG_SEEK_READ)
|
@@ -28,7 +28,7 @@ class TC_Windows_EventLog < Test::Unit::TestCase
|
|
28
28
|
assert_equal(16, EventLogFoo::EVENTLOG_AUDIT_FAILURE)
|
29
29
|
assert_equal(0, EventLogFoo::EVENTLOG_FULL_INFO)
|
30
30
|
end
|
31
|
-
|
31
|
+
|
32
32
|
def test_method_constants
|
33
33
|
assert_not_nil(EventLogFoo::BackupEventLog)
|
34
34
|
assert_not_nil(EventLogFoo::BackupEventLogW)
|
@@ -51,7 +51,7 @@ class TC_Windows_EventLog < Test::Unit::TestCase
|
|
51
51
|
assert_not_nil(EventLogFoo::ReportEvent)
|
52
52
|
assert_not_nil(EventLogFoo::ReportEventW)
|
53
53
|
end
|
54
|
-
|
54
|
+
|
55
55
|
def teardown
|
56
56
|
@foo = nil
|
57
57
|
end
|
data/test/tc_file.rb
CHANGED
@@ -4,34 +4,34 @@
|
|
4
4
|
# Test case for the Windows::File module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/file'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class FileFoo
|
10
|
-
|
10
|
+
include Windows::File
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_File <
|
14
|
-
|
13
|
+
class TC_Windows_File < MiniTest::Unit::TestCase
|
14
|
+
|
15
15
|
def setup
|
16
16
|
@foo = FileFoo.new
|
17
17
|
end
|
18
|
-
|
18
|
+
|
19
19
|
def test_numeric_constants
|
20
|
-
assert_equal(0x00000001, FileFoo::FILE_ATTRIBUTE_READONLY)
|
21
|
-
assert_equal(0x00000002, FileFoo::FILE_ATTRIBUTE_HIDDEN)
|
20
|
+
assert_equal(0x00000001, FileFoo::FILE_ATTRIBUTE_READONLY)
|
21
|
+
assert_equal(0x00000002, FileFoo::FILE_ATTRIBUTE_HIDDEN)
|
22
22
|
assert_equal(0x00000004, FileFoo::FILE_ATTRIBUTE_SYSTEM)
|
23
|
-
assert_equal(0x00000010, FileFoo::FILE_ATTRIBUTE_DIRECTORY)
|
24
|
-
assert_equal(0x00000020, FileFoo::FILE_ATTRIBUTE_ARCHIVE)
|
23
|
+
assert_equal(0x00000010, FileFoo::FILE_ATTRIBUTE_DIRECTORY)
|
24
|
+
assert_equal(0x00000020, FileFoo::FILE_ATTRIBUTE_ARCHIVE)
|
25
25
|
assert_equal(0x00000040, FileFoo::FILE_ATTRIBUTE_ENCRYPTED)
|
26
|
-
assert_equal(0x00000080, FileFoo::FILE_ATTRIBUTE_NORMAL)
|
27
|
-
assert_equal(0x00000100, FileFoo::FILE_ATTRIBUTE_TEMPORARY)
|
28
|
-
assert_equal(0x00000200, FileFoo::FILE_ATTRIBUTE_SPARSE_FILE)
|
29
|
-
assert_equal(0x00000400, FileFoo::FILE_ATTRIBUTE_REPARSE_POINT)
|
30
|
-
assert_equal(0x00000800, FileFoo::FILE_ATTRIBUTE_COMPRESSED)
|
31
|
-
assert_equal(0x00001000, FileFoo::FILE_ATTRIBUTE_OFFLINE)
|
26
|
+
assert_equal(0x00000080, FileFoo::FILE_ATTRIBUTE_NORMAL)
|
27
|
+
assert_equal(0x00000100, FileFoo::FILE_ATTRIBUTE_TEMPORARY)
|
28
|
+
assert_equal(0x00000200, FileFoo::FILE_ATTRIBUTE_SPARSE_FILE)
|
29
|
+
assert_equal(0x00000400, FileFoo::FILE_ATTRIBUTE_REPARSE_POINT)
|
30
|
+
assert_equal(0x00000800, FileFoo::FILE_ATTRIBUTE_COMPRESSED)
|
31
|
+
assert_equal(0x00001000, FileFoo::FILE_ATTRIBUTE_OFFLINE)
|
32
32
|
assert_equal(0x00002000, FileFoo::FILE_ATTRIBUTE_NOT_CONTENT_INDEXED)
|
33
33
|
end
|
34
|
-
|
34
|
+
|
35
35
|
def test_method_constants
|
36
36
|
assert_not_nil(FileFoo::CopyFile)
|
37
37
|
assert_not_nil(FileFoo::CopyFileEx)
|
@@ -61,8 +61,8 @@ class TC_Windows_File < Test::Unit::TestCase
|
|
61
61
|
assert_not_nil(FileFoo::WriteFile)
|
62
62
|
assert_not_nil(FileFoo::WriteFileEx)
|
63
63
|
end
|
64
|
-
|
64
|
+
|
65
65
|
def teardown
|
66
66
|
@foo = nil
|
67
67
|
end
|
68
|
-
end
|
68
|
+
end
|
data/test/tc_file_mapping.rb
CHANGED
@@ -4,25 +4,25 @@
|
|
4
4
|
# Test case for the Windows::FileMapping module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/file_mapping'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class FileMappingFoo
|
10
|
-
|
10
|
+
include Windows::FileMapping
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_FileMapping <
|
14
|
-
|
13
|
+
class TC_Windows_FileMapping < MiniTest::Unit::TestCase
|
14
|
+
|
15
15
|
def setup
|
16
16
|
@foo = FileMappingFoo.new
|
17
17
|
end
|
18
|
-
|
18
|
+
|
19
19
|
def test_numeric_constants
|
20
20
|
assert_equal(0x00000001, FileMappingFoo::FILE_MAP_COPY)
|
21
21
|
assert_equal(0x00000002, FileMappingFoo::FILE_MAP_WRITE)
|
22
22
|
assert_equal(0x00000004, FileMappingFoo::FILE_MAP_READ)
|
23
23
|
assert_equal(983071, FileMappingFoo::FILE_MAP_ALL_ACCESS)
|
24
24
|
end
|
25
|
-
|
25
|
+
|
26
26
|
def test_method_constants
|
27
27
|
assert_not_nil(FileMappingFoo::CreateFileMapping)
|
28
28
|
assert_not_nil(FileMappingFoo::FlushViewOfFile)
|
@@ -31,7 +31,7 @@ class TC_Windows_FileMapping < Test::Unit::TestCase
|
|
31
31
|
assert_not_nil(FileMappingFoo::OpenFileMapping)
|
32
32
|
assert_not_nil(FileMappingFoo::UnmapViewOfFile)
|
33
33
|
end
|
34
|
-
|
34
|
+
|
35
35
|
def teardown
|
36
36
|
@foo = nil
|
37
37
|
end
|
data/test/tc_filesystem.rb
CHANGED
@@ -4,23 +4,23 @@
|
|
4
4
|
# Test case for the Windows::FileSystem module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/filesystem'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class FileSystemFoo
|
10
|
-
|
10
|
+
include Windows::FileSystem
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_FileSystem <
|
14
|
-
|
13
|
+
class TC_Windows_FileSystem < MiniTest::Unit::TestCase
|
14
|
+
|
15
15
|
def setup
|
16
16
|
@foo = FileSystemFoo.new
|
17
17
|
end
|
18
|
-
|
18
|
+
|
19
19
|
def test_method_constants
|
20
20
|
assert_not_nil(FileSystemFoo::GetDiskFreeSpace)
|
21
21
|
assert_not_nil(FileSystemFoo::GetDiskFreeSpaceEx)
|
22
22
|
end
|
23
|
-
|
23
|
+
|
24
24
|
def teardown
|
25
25
|
@foo = nil
|
26
26
|
end
|
data/test/tc_gdi_bitmap.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::GDI::Bitmap module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/gdi/bitmap'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
|
-
class TC_Windows_GDI_Bitmap <
|
9
|
+
class TC_Windows_GDI_Bitmap < MiniTest::Unit::TestCase
|
10
10
|
include Windows::GDI::Bitmap
|
11
11
|
|
12
12
|
def test_methods
|
data/test/tc_gdi_metafile.rb
CHANGED
@@ -4,9 +4,9 @@
|
|
4
4
|
# Test case for the Windows::GDI::MetaFile module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/gdi/metafile'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
|
-
class TC_Windows_GDI_MetaFile <
|
9
|
+
class TC_Windows_GDI_MetaFile < MiniTest::Unit::TestCase
|
10
10
|
include Windows::GDI::MetaFile
|
11
11
|
|
12
12
|
def test_methods
|
data/test/tc_handle.rb
CHANGED
@@ -4,14 +4,13 @@
|
|
4
4
|
# Test case for the Windows::Handle module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/handle'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class HandleFoo
|
10
|
-
|
10
|
+
include Windows::Handle
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_Handle <
|
14
|
-
|
13
|
+
class TC_Windows_Handle < MiniTest::Unit::TestCase
|
15
14
|
def setup
|
16
15
|
@foo = HandleFoo.new
|
17
16
|
end
|
@@ -21,7 +20,7 @@ class TC_Windows_Handle < Test::Unit::TestCase
|
|
21
20
|
assert_equal(0x00000001, HandleFoo::HANDLE_FLAG_INHERIT)
|
22
21
|
assert_equal(0x00000002, HandleFoo::HANDLE_FLAG_PROTECT_FROM_CLOSE)
|
23
22
|
end
|
24
|
-
|
23
|
+
|
25
24
|
def test_method_constants
|
26
25
|
assert_not_nil(HandleFoo::CloseHandle)
|
27
26
|
assert_not_nil(HandleFoo::DuplicateHandle)
|
@@ -29,7 +28,7 @@ class TC_Windows_Handle < Test::Unit::TestCase
|
|
29
28
|
assert_not_nil(HandleFoo::Get_osfhandle)
|
30
29
|
assert_not_nil(HandleFoo::Open_osfhandle)
|
31
30
|
end
|
32
|
-
|
31
|
+
|
33
32
|
def teardown
|
34
33
|
@foo = nil
|
35
34
|
end
|
data/test/tc_library.rb
CHANGED
@@ -4,13 +4,13 @@
|
|
4
4
|
# Test case for the Windows::Library module.
|
5
5
|
#####################################################################
|
6
6
|
require 'windows/library'
|
7
|
-
require '
|
7
|
+
require 'minitest/autorun'
|
8
8
|
|
9
9
|
class LibraryFoo
|
10
|
-
|
10
|
+
include Windows::Library
|
11
11
|
end
|
12
12
|
|
13
|
-
class TC_Windows_Library <
|
13
|
+
class TC_Windows_Library < MiniTest::Unit::TestCase
|
14
14
|
def setup
|
15
15
|
@LibraryFoo = LibraryFoo.new
|
16
16
|
end
|