Skip to content

Commit

Permalink
Adding status valid when missing in file
Browse files Browse the repository at this point in the history
  • Loading branch information
HassanAkbar authored and ronaldtse committed May 15, 2024
1 parent 3897689 commit 0ff36bd
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion lib/tc211/termbase/glossarist/concept.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def register_info
{
"dateAccepted" => date_accepted&.date&.dup,
"id" => uuid,
"status" => entry_status,
"status" => entry_status || "valid",
}.compact
end
end
Expand Down
16 changes: 16 additions & 0 deletions spec/tc211/termbase_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,22 @@
end
end
end

context "concept 18" do
let(:concept) { collection.fetch("18") }

it "should have 11 localized concepts" do
expect(concept.localized_concepts.count).to be(11)
end

context "dan localization with status missing in file" do
let(:localized_concept) { concept.localization("dan") }

it "should have status=valid" do
expect(localized_concept.status).to eq("valid")
end
end
end
end
end
end

0 comments on commit 0ff36bd

Please sign in to comment.