Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
ansible
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ansible
Commits
aefca246
Commit
aefca246
authored
Aug 03, 2015
by
Brian Coca
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #10857 from jeffb-stell/devel
Add test for
https://github.com/ansible/ansible/issues/9851
parents
015b922c
47c3d75c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
0 deletions
+22
-0
test/integration/roles/test_filters/files/9851.txt
+3
-0
test/integration/roles/test_filters/tasks/main.yml
+19
-0
No files found.
test/integration/roles/test_filters/files/9851.txt
0 → 100644
View file @
aefca246
[{
"k": "Quotes \"'\n"
}]
test/integration/roles/test_filters/tasks/main.yml
View file @
aefca246
...
...
@@ -25,6 +25,25 @@
-
name
:
Verify that we workaround a py26 json bug
template
:
src=py26json.j2 dest={{output_dir}}/py26json.templated mode=0644
-
name
:
9851 - Verify that we don't trigger https://github.com/ansible/ansible/issues/9851
copy
:
content
:
"
[{{item|to_nice_json}}]"
dest
:
"
{{output_dir}}/9851.out"
with_items
:
-
{
"
k"
:
"
Quotes
\"
'
\n
"
}
-
name
:
9851 - copy known good output into place
copy
:
src=9851.txt dest={{output_dir}}/9851.txt
-
name
:
9851 - Compare generated json to known good
shell
:
diff {{output_dir}}/9851.out {{output_dir}}/9851.txt
register
:
9851_diff_result
-
name
:
9851 - verify generated file matches known good
assert
:
that
:
-
'
9851_diff_result.stdout
==
""'
-
name
:
fill in a basic template
template
:
src=foo.j2 dest={{output_dir}}/foo.templated mode=0644
register
:
template_result
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment