Skip to content

Commit

Permalink
check for ording error. fix #180
Browse files Browse the repository at this point in the history
  • Loading branch information
masao committed Dec 31, 2024
1 parent d2d1cb6 commit df4f111
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
24 changes: 24 additions & 0 deletions spec/example/example_order.ttl
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<https://example.org/a> a <https://example.org/b>.
<https://example.org/a> <http://purl.org/dc/terms/title> "test title".
<https://example.org/a/b/> a <https://example.org/b>.
<https://example.org/a/b/> <http://example.org/title> "test title 2/".
<https://example.org/a/b> a <https://example.org/b>.
<https://example.org/a/b> <http://example.org/title> "test title 2".
<https://example.org/a/c> a <https://example.org/b>.
<https://example.org/a/c> <http://example.org/title> "test title 3".
<https://example.org/a/d> a <https://example.org/b>.
<https://example.org/a/d> <http://example.org/title> "test title 4".
<https://example.org/a/e> a <https://example.org/b>.
<https://example.org/a/e> <http://example.org/title> "test title 5".
<https://example.org/b> a <https://example.org/a>.
<https://example.org/b> <http://example.org/title> "test title 6".
<https://example.org/b> a <https://example.org/a>.
<https://example.org/b> <http://example.org/title> "test title 6".
<https://example.org/b/a> a <https://example.org/a>.
<https://example.org/b/a> <http://example.org/title> "test title 6".
<https://example.org/b/b> a <https://example.org/a>.
<https://example.org/b/b> <http://example.org/title> "test title 6".
<https://example.org/b/c> a <https://example.org/a>.
<https://example.org/b/c> <http://example.org/title> "test title 6".
<https://example.org/b/d> a <https://example.org/a>.
<https://example.org/b/d> <http://example.org/title> "test title 6".
9 changes: 9 additions & 0 deletions spec/ttl2html_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -782,6 +782,15 @@
html = Capybara.string cont
expect(html).to have_css("div.jumbotron div.description")
end
it "should output files/dirs accurately, even in parallel execution" do
@ttl2html = TTL2HTML::App.new(File.join(spec_base_dir, "example", "example_content.yml"))
@ttl2html.load_turtle(File.join(spec_base_dir, "example", "example_order.ttl"))
expect {
@ttl2html.output_html_files
}.not_to raise_error
expect(Pathname("/tmp/html/a")).to be_directory
expect(Pathname("/tmp/html/b")).to be_directory
end
end
context "#output_turtle_files" do
ttl2html = nil
Expand Down

0 comments on commit df4f111

Please sign in to comment.