Skip to content

Commit e784a0c

Browse files
committed
Add basic parsing test
1 parent e8aa7a2 commit e784a0c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/docurium_test.rb

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,13 @@ def teardown
2828
FileUtils.remove_entry(@dir)
2929
end
3030

31+
def test_can_parse
32+
refute_nil @data
33+
assert_equal [:files, :functions, :callbacks, :globals, :types, :prefix, :groups], @data.keys
34+
files = %w(blob.h callback.h cherrypick.h commit.h common.h errors.h index.h object.h odb.h odb_backend.h oid.h refs.h repository.h revwalk.h signature.h tag.h tree.h types.h)
35+
assert_equal files, @data[:files].map {|d| d[:file] }
36+
end
37+
3138
def test_can_parse_headers
3239
keys = @data.keys.map { |k| k.to_s }.sort
3340
assert_equal ['callbacks', 'files', 'functions', 'globals', 'groups', 'prefix', 'types'], keys

0 commit comments

Comments
 (0)