Beispiel #1
0
	def test_extreme_pop(self):
		_copy(self.file)
		cmds.svn_add(_client_file(self.file))
		_command('push')
		
		assert_raises(SystemExit, _command, 'pop', ['1'])
		assert_raises(SystemExit, _command, 'pop', ['2'])
		assert_raises(SystemExit, _command, 'pop', ['-1'])
Beispiel #2
0
	def test_extreme_delete(self):
		_copy(self.file)
		cmds.svn_add(_client_file(self.file))
		_command('push')
		
		assert_raises(SystemExit, _command, 'remove')
		assert_raises(SystemExit, _command, 'remove', ['1'])
		assert_raises(SystemExit, _command, 'remove', ['-1'])
		
		assert len(_command('remove', ['0'])) == 2
Beispiel #3
0
	def test_0_single_file(self):
		_copy(self.file)
		cmds.svn_add(_client_file(self.file))
		
		_command('push')
		assert not cmds.svn_changes_exist(CLIENT_DIR)
		
		stashes = svnstash.Stashes()
		
		assert len(stashes) == 1
		
		s = stashes[0]
		
		assert s.comment == ''
		assert len(s.get_affected_files()) == 1
		
		_command('pop')
		
		assert cmds.svn_changes_exist(CLIENT_DIR)
		assert len(cmds.svn_changes(CLIENT_DIR)) == 1