Exemplo n.º 1
0
    def test_save_project(self):
        """Check that myclass exists"""
        result = self.myclass

        PROJ_D = {'status': '3 - Alpha',
                  'proj_copyright': 'Copyright (c) 2015 Charlie Taylor',
                  'proj_license': 'MIT', 'author': 'Charlie Taylor',
                  'longDesc': "MyProject tests the creation of a project using"+\
                  " pyHatch.\nShould be a piece of cake... but might not be, "+\
                  "so I test.",
                  'mainClassName': 'MyClass',
                  'simpleDesc': 'My project does this',
                  'version': '0.1.1', 'mainPyFileName': 'main.py',
                  'email': '*****@*****.**',
                  'mainFunctionName': 'my_function',
                  'mainDefinesClass': 'Y'}

        h = Hatch(projName='DocSampCase6', in_test_mode=True, **PROJ_D)
        h.save_project_below_this_dir( r'.' )
Exemplo n.º 2
0
    def test_save_project(self):
        """Check that myclass exists"""
        result = self.myclass

        PROJ_D = {'status': '3 - Alpha',
                  'proj_copyright': 'Copyright (c) 2015 Charlie Taylor',
                  'proj_license': 'MIT', 'author': 'Charlie Taylor',
                  'longDesc': "MyProject tests the creation of a project using"+\
                  " pyHatch.\nShould be a piece of cake... but might not be, "+\
                  "so I test.",
                  'mainClassName': 'MyClass',
                  'simpleDesc': 'My project does this',
                  'version': '0.1.1', 'mainPyFileName': 'main.py',
                  'email': '*****@*****.**',
                  'mainFunctionName': 'my_function',
                  'mainDefinesClass': 'Y'}

        h = Hatch(projName='DocSampCase6', in_test_mode=True, **PROJ_D)
        h.save_project_below_this_dir(r'.')
Exemplo n.º 3
0
import os

from pyhatch.hatch_supt import Hatch

SIMPLEDESC='''PyProTem acts as a temporary project for test purposes.'''

LONGDESC="""Use pyProTem to test tox usage locally, travis CI on checkin to 
GitHub, tk_nosy to watch files locally and alert breakage, operation under 
both python 2 and 3 on Windows and Linux."""

h = Hatch(projName='PyProTem', 
          mainPyFileName='main.py', 
          mainDefinesClass='Y',
          mainClassName='ProTem', 
          mainFunctionName='my_function',
          author='Some Guy', 
          github_user_name='somekindaguy',
          proj_copyright='Copyright (c) 2015 Some Guy',
          proj_license='GPL-3', 
          version='0.1.3', 
          email='*****@*****.**', 
          status='4 - Beta',
          simpleDesc=SIMPLEDESC, 
          longDesc=LONGDESC, 
          year=None,   # if None, set to this year
          organization=None)  # if None, set to author

# This example places project into user home directory
h.save_project_below_this_dir( os.path.expanduser('~/') )

Exemplo n.º 4
0
import os

from pyhatch.hatch_supt import Hatch

SIMPLEDESC = '''PyProTem acts as a temporary project for test purposes.'''

LONGDESC = """Use pyProTem to test tox usage locally, travis CI on checkin to 
GitHub, tk_nosy to watch files locally and alert breakage, operation under 
both python 2 and 3 on Windows and Linux."""

h = Hatch(
    projName='PyProTem',
    mainPyFileName='main.py',
    mainDefinesClass='Y',
    mainClassName='ProTem',
    mainFunctionName='my_function',
    author='Some Guy',
    github_user_name='somekindaguy',
    proj_copyright='Copyright (c) 2015 Some Guy',
    proj_license='GPL-3',
    version='0.1.3',
    email='*****@*****.**',
    status='4 - Beta',
    simpleDesc=SIMPLEDESC,
    longDesc=LONGDESC,
    year=None,  # if None, set to this year
    organization=None)  # if None, set to author

# This example places project into user home directory
h.save_project_below_this_dir(os.path.expanduser('~/'))
Exemplo n.º 5
0
 def setUp(self):
     unittest.TestCase.setUp(self)
     self.myclass = Hatch()