boilerplate_test: fix bad indentation
This commit is contained in:
		@@ -20,33 +20,33 @@ from io import StringIO
 | 
				
			|||||||
import os
 | 
					import os
 | 
				
			||||||
import sys
 | 
					import sys
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
class TestBoilerplate(unittest.TestCase):
 | 
					class TestBoilerplate(unittest.TestCase):
 | 
				
			||||||
  """
 | 
					    """
 | 
				
			||||||
  Note: run this test from the hack/boilerplate directory.
 | 
					    Note: run this test from the hack/boilerplate directory.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  $ python -m unittest boilerplate_test
 | 
					    $ python -m unittest boilerplate_test
 | 
				
			||||||
  """
 | 
					    """
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  def test_boilerplate(self):
 | 
					    def test_boilerplate(self):
 | 
				
			||||||
    os.chdir("test/")
 | 
					        os.chdir("test/")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    class Args(object):
 | 
					        class Args(object):
 | 
				
			||||||
      def __init__(self):
 | 
					            def __init__(self):
 | 
				
			||||||
        self.filenames = []
 | 
					                self.filenames = []
 | 
				
			||||||
        self.rootdir = "."
 | 
					                self.rootdir = "."
 | 
				
			||||||
        self.boilerplate_dir = "../"
 | 
					                self.boilerplate_dir = "../"
 | 
				
			||||||
        self.verbose = True
 | 
					                self.verbose = True
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    # capture stdout
 | 
					        # capture stdout
 | 
				
			||||||
    old_stdout = sys.stdout
 | 
					        old_stdout = sys.stdout
 | 
				
			||||||
    sys.stdout = StringIO.StringIO()
 | 
					        sys.stdout = StringIO.StringIO()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    boilerplate.args = Args()
 | 
					        boilerplate.args = Args()
 | 
				
			||||||
    ret = boilerplate.main()
 | 
					        ret = boilerplate.main()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    output = sorted(sys.stdout.getvalue().split())
 | 
					        output = sorted(sys.stdout.getvalue().split())
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    sys.stdout = old_stdout
 | 
					        sys.stdout = old_stdout
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    self.assertEqual(
 | 
					        self.assertEqual(output, ["././fail.go", "././fail.py"])
 | 
				
			||||||
        output, ['././fail.go', '././fail.py'])
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user