Skip to content

Commit

Permalink
test: Add (failing) test for holocm#24
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Shumaker committed Jan 24, 2017
1 parent dae07d4 commit 089a321
Show file tree
Hide file tree
Showing 10 changed files with 45 additions and 0 deletions.
4 changes: 4 additions & 0 deletions test/14-silent-apply/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
It is desirable that if a user has manually altered a file, but in a
way that is identical to the way that `holo apply` would have altered
it, that holo should accept this change, rather than making the user
first revert it, only to make the same change again.
1 change: 1 addition & 0 deletions test/14-silent-apply/expected-apply-output
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
exit status 0
9 changes: 9 additions & 0 deletions test/14-silent-apply/expected-diff-output
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
diff --holo target/var/lib/holo/files/provisioned/etc/normal.conf target/etc/normal.conf
--- target/var/lib/holo/files/provisioned/etc/normal.conf
+++ target/etc/normal.conf
@@ -1,2 +1,2 @@
-bbb
-bbb
+ccc
+ccc
exit status 0
6 changes: 6 additions & 0 deletions test/14-silent-apply/expected-scan-output
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@

file:target/etc/normal.conf
store at target/var/lib/holo/files/base/etc/normal.conf
apply target/usr/share/holo/files/01-first/etc/normal.conf

exit status 0
16 changes: 16 additions & 0 deletions test/14-silent-apply/expected-tree
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
>> ./etc/holorc = symlink
../../../holorc
>> ./etc/normal.conf = regular
ccc
ccc
>> ./run = dir
>> ./tmp = dir
>> ./usr/share/holo/files/01-first/etc/normal.conf = regular
ccc
ccc
>> ./var/lib/holo/files/base/etc/normal.conf = regular
aaa
aaa
>> ./var/lib/holo/files/provisioned/etc/normal.conf = regular
ccc
ccc
1 change: 1 addition & 0 deletions test/14-silent-apply/source/etc/holorc
2 changes: 2 additions & 0 deletions test/14-silent-apply/source/etc/normal.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ccc
ccc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
ccc
ccc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
aaa
aaa
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
bbb
bbb

0 comments on commit 089a321

Please sign in to comment.