Skip to content

Commit

Permalink
Add Tests to Cover #233
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanzweifel committed Jul 30, 2022
1 parent 9262405 commit dce7e85
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions tests/git-auto-commit.bats
Expand Up @@ -823,3 +823,19 @@ git_auto_commit() {

assert_success
}

@test "detects and commits changed files based on pattern in root and subfolders" {
# Add some .neon files
touch "${FAKE_LOCAL_REPOSITORY}"/new-file-1.neon
mkdir foo;
touch "${FAKE_LOCAL_REPOSITORY}"/foo/new-file-2.neon

INPUT_FILE_PATTERN="**/*.neon *.neon"

run git_auto_commit

assert_success

assert_line --partial "new-file-1.neon"
assert_line --partial "foo/new-file-2.neon"
}

0 comments on commit dce7e85

Please sign in to comment.