win32-eventlog 0.6.3 → 0.6.4
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 +4 -4
- checksums.yaml.gz.sig +2 -0
- data.tar.gz.sig +2 -0
- data/CHANGES +254 -248
- data/MANIFEST +21 -19
- data/README +81 -82
- data/Rakefile +3 -6
- data/certs/djberg96_pub.pem +21 -0
- data/doc/tutorial.txt +136 -136
- data/examples/example_notify.rb +23 -23
- data/examples/example_read.rb +83 -83
- data/examples/example_write.rb +64 -64
- data/lib/win32-eventlog.rb +1 -0
- data/lib/win32/eventlog.rb +1139 -1139
- data/lib/win32/mc.rb +120 -120
- data/lib/win32/windows/constants.rb +56 -56
- data/lib/win32/windows/functions.rb +61 -61
- data/lib/win32/windows/helper.rb +13 -13
- data/lib/win32/windows/structs.rb +30 -30
- data/misc/install_msg.rb +46 -46
- data/misc/rubymsg.mc +35 -35
- data/test/foo.mc +24 -24
- data/test/test_eventlog.rb +319 -319
- data/test/test_mc.rb +64 -64
- data/win32-eventlog.gemspec +30 -30
- metadata +29 -5
- metadata.gz.sig +0 -0
data/test/test_mc.rb
CHANGED
@@ -1,64 +1,64 @@
|
|
1
|
-
############################################################################
|
2
|
-
# test_mc.rb
|
3
|
-
#
|
4
|
-
# Test suite for the win32-mc library. The tests need to run in a specific
|
5
|
-
# order, hence the numerics added to the method names.
|
6
|
-
#
|
7
|
-
# This test case should be run via the 'rake test' Rakefile task.
|
8
|
-
############################################################################
|
9
|
-
require 'test-unit'
|
10
|
-
require 'win32/mc'
|
11
|
-
require 'ptools'
|
12
|
-
include Win32
|
13
|
-
|
14
|
-
class TC_Win32_MC < Test::Unit::TestCase
|
15
|
-
def self.startup
|
16
|
-
Dir.chdir(File.expand_path(File.dirname(__FILE__)))
|
17
|
-
|
18
|
-
@@mc_cmd = File.which('mc')
|
19
|
-
@@rc_cmd = File.which('rc')
|
20
|
-
@@link_cmd = File.which('link')
|
21
|
-
end
|
22
|
-
|
23
|
-
def setup
|
24
|
-
@mc = MC.new('foo.mc')
|
25
|
-
end
|
26
|
-
|
27
|
-
def test_01_version
|
28
|
-
assert_equal('0.1.6', MC::VERSION)
|
29
|
-
end
|
30
|
-
|
31
|
-
def test_02_create_header
|
32
|
-
omit_if(@@mc_cmd.nil?, "'mc' command not found - skipping")
|
33
|
-
assert_respond_to(@mc, :create_header)
|
34
|
-
assert_equal(true, @mc.create_header)
|
35
|
-
end
|
36
|
-
|
37
|
-
def test_03_create_res_file
|
38
|
-
omit_if(@@rc_cmd.nil?, "'rc' command not found - skipping")
|
39
|
-
assert_respond_to(@mc, :create_res_file)
|
40
|
-
assert_equal(true, @mc.create_res_file)
|
41
|
-
end
|
42
|
-
|
43
|
-
def test_04_create_dll_file
|
44
|
-
omit_if(@@link_cmd.nil?, "'link' command not found - skipping")
|
45
|
-
assert_respond_to(@mc, :create_dll_file)
|
46
|
-
assert_equal(true, @mc.create_dll_file)
|
47
|
-
end
|
48
|
-
|
49
|
-
def test_05_clean
|
50
|
-
assert_respond_to(@mc, :clean)
|
51
|
-
assert_nothing_raised{ @mc.clean }
|
52
|
-
end
|
53
|
-
|
54
|
-
def teardown
|
55
|
-
@mc = nil
|
56
|
-
File.delete('foo.dll') if File.exist?('foo.dll')
|
57
|
-
end
|
58
|
-
|
59
|
-
def self.shutdown
|
60
|
-
@@mc_cmd = nil
|
61
|
-
@@rc_cmd = nil
|
62
|
-
@@link_cmd = nil
|
63
|
-
end
|
64
|
-
end
|
1
|
+
############################################################################
|
2
|
+
# test_mc.rb
|
3
|
+
#
|
4
|
+
# Test suite for the win32-mc library. The tests need to run in a specific
|
5
|
+
# order, hence the numerics added to the method names.
|
6
|
+
#
|
7
|
+
# This test case should be run via the 'rake test' Rakefile task.
|
8
|
+
############################################################################
|
9
|
+
require 'test-unit'
|
10
|
+
require 'win32/mc'
|
11
|
+
require 'ptools'
|
12
|
+
include Win32
|
13
|
+
|
14
|
+
class TC_Win32_MC < Test::Unit::TestCase
|
15
|
+
def self.startup
|
16
|
+
Dir.chdir(File.expand_path(File.dirname(__FILE__)))
|
17
|
+
|
18
|
+
@@mc_cmd = File.which('mc')
|
19
|
+
@@rc_cmd = File.which('rc')
|
20
|
+
@@link_cmd = File.which('link')
|
21
|
+
end
|
22
|
+
|
23
|
+
def setup
|
24
|
+
@mc = MC.new('foo.mc')
|
25
|
+
end
|
26
|
+
|
27
|
+
def test_01_version
|
28
|
+
assert_equal('0.1.6', MC::VERSION)
|
29
|
+
end
|
30
|
+
|
31
|
+
def test_02_create_header
|
32
|
+
omit_if(@@mc_cmd.nil?, "'mc' command not found - skipping")
|
33
|
+
assert_respond_to(@mc, :create_header)
|
34
|
+
assert_equal(true, @mc.create_header)
|
35
|
+
end
|
36
|
+
|
37
|
+
def test_03_create_res_file
|
38
|
+
omit_if(@@rc_cmd.nil?, "'rc' command not found - skipping")
|
39
|
+
assert_respond_to(@mc, :create_res_file)
|
40
|
+
assert_equal(true, @mc.create_res_file)
|
41
|
+
end
|
42
|
+
|
43
|
+
def test_04_create_dll_file
|
44
|
+
omit_if(@@link_cmd.nil?, "'link' command not found - skipping")
|
45
|
+
assert_respond_to(@mc, :create_dll_file)
|
46
|
+
assert_equal(true, @mc.create_dll_file)
|
47
|
+
end
|
48
|
+
|
49
|
+
def test_05_clean
|
50
|
+
assert_respond_to(@mc, :clean)
|
51
|
+
assert_nothing_raised{ @mc.clean }
|
52
|
+
end
|
53
|
+
|
54
|
+
def teardown
|
55
|
+
@mc = nil
|
56
|
+
File.delete('foo.dll') if File.exist?('foo.dll')
|
57
|
+
end
|
58
|
+
|
59
|
+
def self.shutdown
|
60
|
+
@@mc_cmd = nil
|
61
|
+
@@rc_cmd = nil
|
62
|
+
@@link_cmd = nil
|
63
|
+
end
|
64
|
+
end
|
data/win32-eventlog.gemspec
CHANGED
@@ -1,30 +1,30 @@
|
|
1
|
-
require 'rubygems'
|
2
|
-
|
3
|
-
Gem::Specification.new do |spec|
|
4
|
-
spec.name = 'win32-eventlog'
|
5
|
-
spec.version = '0.6.
|
6
|
-
spec.authors = ['Daniel J. Berger', 'Park Heesob']
|
7
|
-
spec.license = 'Artistic 2.0'
|
8
|
-
spec.email = 'djberg96@gmail.com'
|
9
|
-
spec.homepage = 'http://github.com/djberg96/win32-eventlog'
|
10
|
-
spec.summary = 'Interface for the MS Windows Event Log.'
|
11
|
-
spec.test_files = Dir['test/*.rb']
|
12
|
-
spec.files = Dir['**/*'].reject{ |f| f.include?('git') }
|
13
|
-
|
14
|
-
|
15
|
-
spec.extra_rdoc_files = ['README', 'CHANGES', 'MANIFEST', 'doc/tutorial.txt']
|
16
|
-
|
17
|
-
spec.add_dependency('ffi')
|
18
|
-
spec.add_development_dependency('test-unit')
|
19
|
-
spec.add_development_dependency('rake')
|
20
|
-
spec.add_development_dependency('ptools')
|
21
|
-
|
22
|
-
spec.description = <<-EOF
|
23
|
-
The win32-eventlog library provides an interface to the MS Windows event
|
24
|
-
log. Event logging provides a standard, centralized way for applications
|
25
|
-
(and the operating system) to record important software and hardware
|
26
|
-
events. The event-logging service stores events from various sources in a
|
27
|
-
single collection called an event log. This library allows you to inspect
|
28
|
-
existing logs as well as create new ones.
|
29
|
-
EOF
|
30
|
-
end
|
1
|
+
require 'rubygems'
|
2
|
+
|
3
|
+
Gem::Specification.new do |spec|
|
4
|
+
spec.name = 'win32-eventlog'
|
5
|
+
spec.version = '0.6.4'
|
6
|
+
spec.authors = ['Daniel J. Berger', 'Park Heesob']
|
7
|
+
spec.license = 'Artistic 2.0'
|
8
|
+
spec.email = 'djberg96@gmail.com'
|
9
|
+
spec.homepage = 'http://github.com/djberg96/win32-eventlog'
|
10
|
+
spec.summary = 'Interface for the MS Windows Event Log.'
|
11
|
+
spec.test_files = Dir['test/*.rb']
|
12
|
+
spec.files = Dir['**/*'].reject{ |f| f.include?('git') }
|
13
|
+
spec.cert_chain = ['certs/djberg96_pub.pem']
|
14
|
+
|
15
|
+
spec.extra_rdoc_files = ['README', 'CHANGES', 'MANIFEST', 'doc/tutorial.txt']
|
16
|
+
|
17
|
+
spec.add_dependency('ffi')
|
18
|
+
spec.add_development_dependency('test-unit')
|
19
|
+
spec.add_development_dependency('rake')
|
20
|
+
spec.add_development_dependency('ptools')
|
21
|
+
|
22
|
+
spec.description = <<-EOF
|
23
|
+
The win32-eventlog library provides an interface to the MS Windows event
|
24
|
+
log. Event logging provides a standard, centralized way for applications
|
25
|
+
(and the operating system) to record important software and hardware
|
26
|
+
events. The event-logging service stores events from various sources in a
|
27
|
+
single collection called an event log. This library allows you to inspect
|
28
|
+
existing logs as well as create new ones.
|
29
|
+
EOF
|
30
|
+
end
|
metadata
CHANGED
@@ -1,15 +1,37 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: win32-eventlog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel J. Berger
|
8
8
|
- Park Heesob
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
|
-
cert_chain:
|
12
|
-
|
11
|
+
cert_chain:
|
12
|
+
- |
|
13
|
+
-----BEGIN CERTIFICATE-----
|
14
|
+
MIIDcDCCAligAwIBAgIBATANBgkqhkiG9w0BAQUFADA/MREwDwYDVQQDDAhkamJl
|
15
|
+
cmc5NjEVMBMGCgmSJomT8ixkARkWBWdtYWlsMRMwEQYKCZImiZPyLGQBGRYDY29t
|
16
|
+
MB4XDTE1MDkwMjIwNDkxOFoXDTE2MDkwMTIwNDkxOFowPzERMA8GA1UEAwwIZGpi
|
17
|
+
ZXJnOTYxFTATBgoJkiaJk/IsZAEZFgVnbWFpbDETMBEGCgmSJomT8ixkARkWA2Nv
|
18
|
+
bTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAMyTkvXqRp6hLs9eoJOS
|
19
|
+
Hmi8kRYbq9Vkf15/hMxJpotYMgJVHHWrmDcC5Dye2PbnXjTkKf266Zw0PtT9h+lI
|
20
|
+
S3ts9HO+vaCFSMwFFZmnWJSpQ3CNw2RcHxjWkk9yF7imEM8Kz9ojhiDXzBetdV6M
|
21
|
+
gr0lV/alUr7TNVBDngbXEfTWscyXh1qd7xZ4EcOdsDktCe5G45N/o3662tPQvJsi
|
22
|
+
FOF0CM/KuBsa/HL1/eoEmF4B3EKIRfTHrQ3hu20Kv3RJ88QM4ec2+0dd97uX693O
|
23
|
+
zv6981fyEg+aXLkxrkViM/tz2qR2ZE0jPhHTREPYeMEgptRkTmWSKAuLVWrJEfgl
|
24
|
+
DtkCAwEAAaN3MHUwCQYDVR0TBAIwADALBgNVHQ8EBAMCBLAwHQYDVR0OBBYEFEwe
|
25
|
+
nn6bfJADmuIDiMSOzedOrL+xMB0GA1UdEQQWMBSBEmRqYmVyZzk2QGdtYWlsLmNv
|
26
|
+
bTAdBgNVHRIEFjAUgRJkamJlcmc5NkBnbWFpbC5jb20wDQYJKoZIhvcNAQEFBQAD
|
27
|
+
ggEBAHmNOCWoDVD75zHFueY0viwGDVP1BNGFC+yXcb7u2GlK+nEMCORqzURbYPf7
|
28
|
+
tL+/hzmePIRz7i30UM//64GI1NLv9jl7nIwjhPpXpf7/lu2I9hOTsvwSumb5UiKC
|
29
|
+
/sqBxI3sfj9pr79Wpv4MuikX1XPik7Ncb7NPsJPw06Lvyc3Hkg5X2XpPtLtS+Gr2
|
30
|
+
wKJnmzb5rIPS1cmsqv0M9LPWflzfwoZ/SpnmhagP+g05p8bRNKjZSA2iImM/GyYZ
|
31
|
+
EJYzxdPOrx2n6NYR3Hk+vHP0U7UBSveI6+qx+ndQYaeyCn+GRX2PKS9h66YF/Q1V
|
32
|
+
tGSHgAmcLlkdGgan182qsE/4kKM=
|
33
|
+
-----END CERTIFICATE-----
|
34
|
+
date: 2015-10-25 00:00:00.000000000 Z
|
13
35
|
dependencies:
|
14
36
|
- !ruby/object:Gem::Dependency
|
15
37
|
name: ffi
|
@@ -87,10 +109,12 @@ files:
|
|
87
109
|
- MANIFEST
|
88
110
|
- README
|
89
111
|
- Rakefile
|
112
|
+
- certs/djberg96_pub.pem
|
90
113
|
- doc/tutorial.txt
|
91
114
|
- examples/example_notify.rb
|
92
115
|
- examples/example_read.rb
|
93
116
|
- examples/example_write.rb
|
117
|
+
- lib/win32-eventlog.rb
|
94
118
|
- lib/win32/eventlog.rb
|
95
119
|
- lib/win32/mc.rb
|
96
120
|
- lib/win32/windows/constants.rb
|
@@ -122,8 +146,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
122
146
|
- !ruby/object:Gem::Version
|
123
147
|
version: '0'
|
124
148
|
requirements: []
|
125
|
-
rubyforge_project:
|
126
|
-
rubygems_version: 2.4.
|
149
|
+
rubyforge_project:
|
150
|
+
rubygems_version: 2.4.8
|
127
151
|
signing_key:
|
128
152
|
specification_version: 4
|
129
153
|
summary: Interface for the MS Windows Event Log.
|
metadata.gz.sig
ADDED
Binary file
|