minor fixes and removed code duplication in FileBag tests