def precondition(self): TestHelper.execute_source(self.cfg, ''' mkdir dir echo "Dummy content" >> dir/file echo "Dummy content of file 2" >> dir/file2 ln -s dir/file link ''')
def cleanupWorkspaceImpl(self): # additional task to have permission to cleanup TestHelper.execute_source( self.cfg, ''' chmod +rwx -R . ''') CachefsSystemTest.cleanupWorkspaceImpl(self)
def precondition(self): TestHelper.execute_source(self.cfg, ''' mkdir i echo 'dummy content' >> i/2.txt chmod ugo+rwx i/2.txt ln -s i/2.txt 2.txt ''')
def precondition(self): TestHelper.execute_source( self.cfg, ''' mkdir dir echo "Dummy content" >> dir/file echo "Dummy content of file 2" >> dir/file2 ln -s dir/file link ''')
def precondition(self): TestHelper.execute_source( self.cfg, ''' mkdir i echo 'dummy content' >> i/2.txt chmod ugo+rwx i/2.txt ln -s i/2.txt 2.txt ''')
def precondition(self): TestHelper.execute_source(self.cfg, ''' mkdir -p a/b/c mkdir -p e/f/g touch e/f/g/1.txt mkdir -p i/f/g touch i/f/g/2.txt ln -s ../../../i/f/g e/f/g/j ln -s a b ln -s ../../../i/f/g/2.txt e/f/g/link_to_e ''')
def precondition(self): TestHelper.execute_source( self.cfg, ''' mkdir -p a/b/c mkdir -p e/f/g touch e/f/g/1.txt mkdir -p i/f/g touch i/f/g/2.txt ln -s ../../../i/f/g e/f/g/j ln -s a b ln -s ../../../i/f/g/2.txt e/f/g/link_to_e ''')
def create_dir(permissions): TestHelper.execute_source(self.cfg, ''' mkdir {pmss:o}_dir chmod {pmss:o} {pmss:o}_dir '''.format( pmss=permissions)) # x:o - i.e. x converted to oct format
def create_file(permissions): TestHelper.execute_source(self.cfg, ''' touch {pmss:o} chmod {pmss:o} {pmss:o} '''.format( pmss=permissions)) # x:o - i.e. x converted to oct format
def cleanupWorkspaceImpl(self): # additional task to have permission to cleanup TestHelper.execute_source(self.cfg, ''' chmod +rwx -R . ''') CachefsSystemTest.cleanupWorkspaceImpl(self)
def create_dir(permissions): TestHelper.execute_source(self.cfg, ''' mkdir {pmss:o}_dir chmod {pmss:o} {pmss:o}_dir '''.format(pmss = permissions)) # x:o - i.e. x converted to oct format
def create_file(permissions): TestHelper.execute_source(self.cfg, ''' touch {pmss:o} chmod {pmss:o} {pmss:o} '''.format(pmss = permissions)) # x:o - i.e. x converted to oct format