示例#1
0
def get_translation_filename(filename):
    return repyhelper._get_module_name(filename) + ".py"
示例#2
0
def get_translation_filename(filename):
    return repyhelper._get_module_name(filename) + '.py'
示例#3
0
  No output indicates success
  
"""

import os
import repyhelper
import test_utils
  
#The (preexisting) repy file to use as a reference for translating
SRCFILE = "rhtest_filetests.r2py"

#The temporary file to create to perform checks against
TESTFILE = "rhtest_filetests_new.r2py"

#The translation name corresponding to TESTFILE
TESTFILE_TR = repyhelper._get_module_name(TESTFILE) + ".py"



def create_testfile(filename, contents):
  """
  Create a file in the current directory with a specified translation tagline file tag
  returns the name of the created file
  """
  fh = open(filename, 'w')
  print >> fh, contents
  fh.close()
  return filename
  
  
create_testfile(TESTFILE, repyhelper.TRANSLATION_TAGLINE)
示例#4
0
  No output indicates success
  
"""

import os
import repyhelper
import test_utils
  
#The (preexisting) repy file to use as a reference for translating
SRCFILE = "rhtest_filetests.repy"

#The temporary file to create to perform checks against
TESTFILE = "rhtest_filetests_new.repy"

#The translation name corresponding to TESTFILE
TESTFILE_TR = repyhelper._get_module_name(TESTFILE) + ".py"



def create_testfile(filename, contents):
  """
  Create a file in the current directory with a specified translation tagline file tag
  returns the name of the created file
  """
  fh = open(filename, 'w')
  print >> fh, contents
  fh.close()
  return filename
  
  
create_testfile(TESTFILE, repyhelper.TRANSLATION_TAGLINE)