void () { HgRepository hgRepository = HgRepositoryImpl.getInstance(myRepository, myProject, myProject); assertNotNull(hgRepository); myValidator = new HgBranchReferenceValidator(hgRepository); cd(myRepository); hg("branch '" + BRANCH_NAME + "'"); String firstFile = "file.txt"; echo(firstFile, BRANCH_NAME); hg("commit -m 'createdBranch " + BRANCH_NAME + "' "); hg("branch '" + UNCOMMITTED_BRANCH + "'"); hgRepository.update(); }