Skip to content

Commit

Permalink
Specify local db contents after delete
Browse files Browse the repository at this point in the history
  • Loading branch information
laurilehmijoki committed Jun 8, 2014
1 parent f7e0571 commit e5c04e8
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/test/scala/s3/website/S3WebsiteSpec.scala
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,15 @@ class S3WebsiteSpec extends Specification {
sentDelete must equalTo("obsolete.txt")
}

"delete the local db record for the file if the user deletes the file" in new AllInSameDirectory with EmptySite with MockAWS with DefaultRunMode {
setLocalFileWithContent(("file.txt", "first run"))
push
setS3Files(S3File("file.txt", md5Hex("first run")))
FileUtils.deleteQuietly(new File(siteDirectory, "file.txt"))
push
FileUtils.readLines(localDatabase) must beEmpty
}

"push new files to the bucket" in new AllInSameDirectory with EmptySite with MockAWS with DefaultRunMode {
push
setLocalFile("newfile.txt")
Expand Down

0 comments on commit e5c04e8

Please sign in to comment.