Implement `file_append' task action

This commit is contained in:
Thibault Jouan
2014-03-05 02:38:00 +00:00
parent b1c7ff27b4
commit 387f37f3f5
6 changed files with 95 additions and 3 deletions

View File

@@ -0,0 +1,17 @@
@sshd
Feature: `file_append' task action
Background:
Given a remote file named "some_file" with "some content"
Scenario: appends given content to requested file
Given a recipe with:
"""
target 'some_host.test'
task :append_content_to_file do
file_append 'some_file', ' added'
end
"""
When I successfully execute the recipe
Then the remote file "some_file" must contain exactly "some content added"