Example #1
0
    def test_create_cfg(self):
        from plock.install import Installer
        from tempfile import mkdtemp
        plock = Installer()
        plock.directory = mkdtemp()
        plock.create_cfg(('one', 'two', 'three'))

        with open(os.path.join(plock.directory, 'buildout.cfg'), 'r') as f:
            content = f.read()

        self.assertIn('one', content)
        self.assertIn('two', content)
        self.assertIn('three', content)
Example #2
0
File: tests.py Project: href/plock
    def test_create_cfg(self):
        from plock.install import Installer
        from tempfile import mkdtemp
        plock = Installer()
        plock.directory = mkdtemp()
        plock.create_cfg(('one', 'two', 'three'))

        with open(os.path.join(plock.directory, 'buildout.cfg'), 'r') as f:
            content = f.read()

        self.assertIn('one', content)
        self.assertIn('two', content)
        self.assertIn('three', content)
Example #3
0
 def test_install_plone(self):
     from mock import Mock
     from plock.install import Installer
     from tempfile import mkdtemp
     plock = Installer()
     args = Mock()
     args.install_dir = mkdtemp()
     args.install_addon = None
     args.list_addons = False
     args.raw = False
     args.write_only = False
     args.extends = None
     args.unified_only = False
     plock.install_plone(args, test=True)
Example #4
0
 def test_create_cfg(self):
     from plock.install import Installer
     from tempfile import mkdtemp
     plock = Installer()
     plock.directory = mkdtemp()
     buildout_cfg = os.path.join(plock.directory, 'buildout.cfg')
     heroku_cfg = os.path.join(plock.directory, 'heroku.cfg')
     plock.create_cfg(
         buildout_cfg,
         heroku_cfg,
         extends='https://raw.github.com/plock/pins/master/dev')
     with open(buildout_cfg, 'r') as f:
         file_contents = f.read()
     self.assertIn('https://raw.github.com/plock/pins/master/dev',
                   file_contents)
Example #5
0
File: tests.py Project: href/plock
 def test_run_buildout(self):
     from plock.install import Installer
     plock = Installer()
     plock.run_buildout(test=True)
Example #6
0
 def test_run_buildout(self):
     from mock import Mock
     from plock.install import Installer
     plock = Installer()
     args = Mock()
     plock.run_buildout(args, test=True)
Example #7
0
 def test_run_buildout(self):
     from plock.install import Installer
     plock = Installer()
     plock.run_buildout(test=True)