Skip to content

Commit 732ecff

Browse files
committed
(PUP-10025) fix top-level docs output from puppet describe
This fixes #208
1 parent 6423b76 commit 732ecff

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

lib/puppet/resource_api.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,8 @@ def register_type(definition)
3535
end
3636

3737
Puppet::Type.newtype(definition[:name].to_sym) do
38-
@docs = definition[:desc]
38+
# The :desc value is already cleaned up by the TypeDefinition validation
39+
@doc = definition[:desc]
3940
@type_definition = type_def
4041

4142
# Keeps a copy of the provider around. Weird naming to avoid clashes with puppet's own `provider` member

spec/puppet/resource_api_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161

6262
it { is_expected.not_to be_nil }
6363
it { is_expected.to be_respond_to :instances }
64-
it { expect(type.instance_variable_get(:@docs)).to eq 'the docs' }
64+
it { expect(type.instance_variable_get(:@doc)).to eq 'the docs' }
6565
end
6666
end
6767

0 commit comments

Comments
 (0)