Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -315,12 +315,14 @@ false

#### `Stdlib::Httpsurl`

Matches HTTPS URLs.
Matches HTTPS URLs, it is case a insensitive match.

Acceptable input example:

```shell
https://hello.com

HTTPS://HELLO.COM
```

Unacceptable input example:
Expand All @@ -331,14 +333,16 @@ httds://notquiteright.org`

#### `Stdlib::Httpurl`

Matches both HTTPS and HTTP URLs.
Matches both HTTPS and HTTP URLs, it is a case insensitive match.

Acceptable input example:

```shell
https://hello.com

http://hello.com

HTTP://HELLO.COM
```

Unacceptable input example:
Expand Down
2 changes: 1 addition & 1 deletion spec/type_aliases/httpsurl_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
if Puppet::Util::Package.versioncmp(Puppet.version, '4.5.0') >= 0
describe 'Stdlib::HTTPSUrl' do
describe 'valid handling' do
['https://hello.com', 'https://notcreative.org', 'https://notexciting.co.uk', 'https://graphemica.com/❤', 'https://graphemica.com/緩'].each do |value|
['https://hello.com', 'https://notcreative.org', 'https://notexciting.co.uk', 'https://graphemica.com/❤', 'https://graphemica.com/緩', 'HTTPS://FOO.com'].each do |value|
describe value.inspect do
it { is_expected.to allow_value(value) }
end
Expand Down
4 changes: 2 additions & 2 deletions spec/type_aliases/httpurl_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
if Puppet::Util::Package.versioncmp(Puppet.version, '4.5.0') >= 0
describe 'Stdlib::HTTPUrl' do
describe 'valid handling' do
['https://hello.com', 'https://notcreative.org', 'https://canstillaccepthttps.co.uk', 'http://anhttp.com', 'http://runningoutofideas.gov', 'http://', 'http://graphemica.com/❤',
'http://graphemica.com/'].each do |value|
['https://hello.com', 'https://notcreative.org', 'https://canstillaccepthttps.co.uk', 'http://anhttp.com', 'http://runningoutofideas.gov',
'http://', 'http://graphemica.com/❤', 'http://graphemica.com/緩', 'HTTPS://FOO.COM', 'HTTP://BAR.COM'].each do |value|
describe value.inspect do
it { is_expected.to allow_value(value) }
end
Expand Down
2 changes: 1 addition & 1 deletion types/httpsurl.pp
Original file line number Diff line number Diff line change
@@ -1 +1 @@
type Stdlib::HTTPSUrl = Pattern[/^https:\/\//]
type Stdlib::HTTPSUrl = Pattern[/(?i:^https:\/\/)/]
2 changes: 1 addition & 1 deletion types/httpurl.pp
Original file line number Diff line number Diff line change
@@ -1 +1 @@
type Stdlib::HTTPUrl = Pattern[/^https?:\/\//]
type Stdlib::HTTPUrl = Pattern[/(?i:^https?:\/\/)/]