# Path: handroll/scaffolder.py
# BUILTIN_SCAFFOLDS = {
#     'default': _('A complete site to get you going'),
# }
# SCAFFOLDS_PATH = os.path.join(os.path.dirname(__file__), 'scaffolds')
# def make(scaffold, site):
# def list_scaffolds():
# def display_scaffold(scaffold, label):
# def get_label(scaffold):
# 
# Path: handroll/exceptions.py
# class AbortError(Exception):
#     """Any fatal errors that would prevent handroll from proceeding should
#     signal with the ``AbortError`` exception."""
# 
# Path: handroll/i18n.py

# 
# Path: handroll/tests/testcase.py
# class TestCase(unittest.TestCase):
# 
#     def __init__(self, methodName='runTest'):
#         super(TestCase, self).__init__(methodName)
#         self.factory = Factory()


import os
import tempfile
import mock
from handroll import scaffolder
from handroll.exceptions import AbortError
from handroll.i18n import _
from handroll.tests import TestCase
# Copyright (c) 2017, Matt Layman





class TestScaffolder(TestCase):

    def test_default_scaffolder_label(self):
        label = scaffolder.get_label('default')
        self.assertEqual(_('A complete site to get you going'), label)

    def test_list_format(self):
        display = scaffolder.display_scaffold('scaffold', 'It rocks')
        self.assertEqual('  scaffold    | It rocks', display)
        display = scaffolder.display_scaffold('short', 'Rocks too')
        self.assertEqual('  short       | Rocks too', display)

    @mock.patch('handroll.scaffolder.display_scaffold')
    def test_displays_scaffolds(self, display_scaffold):

# Path: handroll/scaffolder.py
# BUILTIN_SCAFFOLDS = {
#     'default': _('A complete site to get you going'),
# }
# SCAFFOLDS_PATH = os.path.join(os.path.dirname(__file__), 'scaffolds')
# def make(scaffold, site):
# def list_scaffolds():
# def display_scaffold(scaffold, label):
# def get_label(scaffold):
# 
# Path: handroll/exceptions.py
# class AbortError(Exception):
#     """Any fatal errors that would prevent handroll from proceeding should
#     signal with the ``AbortError`` exception."""
# 
# Path: handroll/i18n.py

# 
# Path: handroll/tests/testcase.py
# class TestCase(unittest.TestCase):
# 
#     def __init__(self, methodName='runTest'):
#         super(TestCase, self).__init__(methodName)
#         self.factory = Factory()


# Path: handroll/tests/test_scaffolder.py
import os
import tempfile
import mock
from handroll import scaffolder
from handroll.exceptions import AbortError
from handroll.i18n import _
from handroll.tests import TestCase

# Copyright (c) 2017, Matt Layman





class TestScaffolder(TestCase):

    def test_default_scaffolder_label(self):
        label = scaffolder.get_label('default')
        self.assertEqual(_('A complete site to get you going'), label)

    def test_list_format(self):
        display = scaffolder.display_scaffold('scaffold', 'It rocks')
        self.assertEqual('  scaffold    | It rocks', display)
        display = scaffolder.display_scaffold('short', 'Rocks too')
        self.assertEqual('  short       | Rocks too', display)

    @mock.patch('handroll.scaffolder.display_scaffold')
    def test_displays_scaffolds(self, display_scaffold):

        scaffolder.list_scaffolds()