Arnaud Grausem avatar Arnaud Grausem committed e205d7e

pep8 check

Comments (0)

Files changed (7)

src/adama/__init__.py

 
 
 def sir_yes_sir(module='', doc='', options=(), version='', argv=None):
-    """Launches the right order or displaying the help for a command or an order
-    directly from command line.
+    """Launches the right order or displaying the help for a command or an
+    order directly from command line.
     """
     argv = argv if argv is not None else sys.argv[:]
     command = os.path.basename(argv[0])
             else:
                 return order(argv[2:])
 
+
 def call_order(module_name, order_name, *args, **kwargs):
     """Calls an order from another python script directly
     """

src/adama/commandment.py

             result = order_error()
         return result
 
+
 class Commander(QG):
     """Program class
     """
 {1}{2}
 
 """
-        create_help = "\n\nType 'adama create_order [options] {0} <order_name>'\
+        create_help = "\n\nType 'adama create_order [options] {0} <order_name>\
  to create one".format(self.module)
         # Formats the epilog
         decrypter.epilog = epilog.format(
             available_orders = "No orders available."
         return available.format(available_orders)
 
-
     def execute(self):
         return self.usage()
 
 
     def __init__(self, module, command=''):
         super(BaseOrder, self).__init__(module, command=command)
-        self.name = self.__class__.__module__.split('.')[-1] \
+        self.name = self.__class__.__module__.split('.')[-1]
 
     def usage(self):
         """Usage of a command

src/adama/orders/__init__.py

     """
     with file(filename, 'a'):
         os.utime(filename, times)
-

src/adama/orders/create_program.py

 from ..commandment import BaseOrder
 from . import get_module, get_template, get_command
 
+
 class Order(BaseOrder):
     """Creates a command line program for your application that will look for
 orders

src/adama/tests/__init__.py

     """No shell printing for help when lauching tests
     """
     print_functions = (QG.explanations, AdamaError.__call__)
+
     def wrap(**kwargs):
         """Wrapper for the printing function"""
         for function in print_functions:
         for function in print_functions:
             function.im_func.func_defaults = (True, )
         return result
+
     return wrap
 
 

src/adama/tests/test_orders.py

         with self.assertRaises(OrderError) as order_error:
             call_order('adama', 'create_program')
         exception = order_error.exception
-        assert exception.message == 'The create_program order has one required \
-argument'
+        assert exception.message == 'The create_program order has one required\
+ argument'
 
     def test_command_name(self):
         """Tests creating a command with a name defined

src/adama/tests/test_parsing_args.py

     """Tests the help message and the way they are displayed
     """
 
-
     def test_no_args(self):
         """No argument shell return
         """
     def test_order_execution(self):
         """Order executed shell return
         """
-        assert _sir_yes_sir(module=self.module, argv=[self.command, 'add']) == 0
+        assert _sir_yes_sir(module=self.module, argv=[self.command, 'add']) \
+            == 0
 
 
 class TestDirectLaunchOrder(TestBaseOrders):
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.