Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Documentation: update the docs strings #126

Merged
merged 1 commit into from Feb 17, 2023
Merged

Documentation: update the docs strings #126

merged 1 commit into from Feb 17, 2023

Conversation

b4ldr
Copy link
Member

@b4ldr b4ldr commented Feb 16, 2023

Also change the signature of the functions to make use of optional_block_param

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Repeating answer, so only commented them once :)

lib/puppet/functions/dns_a.rb Show resolved Hide resolved
lib/puppet/functions/dns_a.rb Outdated Show resolved Hide resolved
Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can even consider stricter types, like Stdlib::IP::Address::Nosubnet and Stdlib::Fqdn for return types, but this is already an improvement.

It does look like the tests uncovered some issues though, so it looks like return_type does validate the type as well. Which I'd consider a nice bonus :)

lib/puppet/functions/dnsquery/rlookup.rb Outdated Show resolved Hide resolved
lib/puppet/functions/dnsquery/soa.rb Outdated Show resolved Hide resolved
Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other the failing tests, 👍

spec/functions/dnsquery_mx_spec.rb Show resolved Hide resolved
spec/functions/dnsquery_ptr_spec.rb Show resolved Hide resolved
@b4ldr b4ldr force-pushed the fix_docstrings branch 5 times, most recently from 6d5058a to 3ca9600 Compare February 17, 2023 15:23
Also change the signature of the functions to make use of
optional_block_param

We also improve the type validation which requires adding a dependency
on stdlib
@b4ldr b4ldr merged commit e913f5c into master Feb 17, 2023
@b4ldr b4ldr deleted the fix_docstrings branch February 17, 2023 15:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants