Skip to content

Commit

Permalink
Fixes tags_generator_test
Browse files Browse the repository at this point in the history
Added explicit mock for `Foreman.instance_id`
  • Loading branch information
ShimShtein committed Dec 28, 2023
1 parent b8552ee commit b773636
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/unit/tags_generator_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ class TagsGeneratorTest < ActiveSupport::TestCase
end

test 'generates tags for a single host' do
instance_id = Foreman.uuid
Foreman.stubs(:instance_id).returns(instance_id)

generator = create_generator

actual = generator.generate.group_by { |key, value| key }
Expand Down

0 comments on commit b773636

Please sign in to comment.