Skip to content

add failing test for issue 777 #782

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

Closed
wants to merge 4 commits into from
Closed
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
14 changes: 14 additions & 0 deletions tests/Util/yaml_fixtures/array_double_quoted_80_value_single.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
caddy:
ports:
- "foo:foo"
volumes:
- caddy_data
===
$data['caddy']['ports'][] = "bar:baz";
===
caddy:
ports:
- "foo:foo"
- 'bar:baz'
volumes:
- caddy_data
14 changes: 14 additions & 0 deletions tests/Util/yaml_fixtures/array_double_quoted_foo_value.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
caddy:
ports:
- "foo:foo"
volumes:
- caddy_data
===
$data['caddy']['ports'][] = 'bar:baz';
===
caddy:
ports:
- "foo:foo"
- 'bar:baz'
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This test passes. but not w/ "80:80"

Copy link
Member

Choose a reason for hiding this comment

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

So we don't change the existing double quotes to single quotes. It's only that the NEW keys we add are double quotes? If so, I think it's fine.

volumes:
- caddy_data
14 changes: 14 additions & 0 deletions tests/Util/yaml_fixtures/array_double_quoted_value.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
caddy:
ports:
- "80:80"
Copy link
Member

Choose a reason for hiding this comment

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

For purposes of figuring out the root cause, if you changed this from "80:80" to "foo_bar", does the error happen?

Or, if you use '80:80' with single quotes - error or no?

volumes:
- caddy_data
===
$data['caddy']['ports'][] = "443:443";
Copy link
Member

Choose a reason for hiding this comment

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

Again for purposes of figuring out the root cause, if you changed this from "443:443" to "foo_bar", does the error happen?

===
caddy:
ports:
- "80:80"
- "443:443"
volumes:
- caddy_data
6 changes: 6 additions & 0 deletions tests/Util/yaml_fixtures/array_simple_double_quotes.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
caddy:
===
$data['caddy'][] = "\"443\"";
===
caddy:
- "443"