Klimi's new dotfiles with stow.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
477 B

5 years ago
  1. # coding: utf-8
  2. """Tests for the elpy.autopep8 module"""
  3. import unittest
  4. import os
  5. from elpy import auto_pep8
  6. from elpy.tests.support import BackendTestCase
  7. class Autopep8TestCase(BackendTestCase):
  8. def setUp(self):
  9. if not auto_pep8.autopep8:
  10. raise unittest.SkipTest
  11. def test_fix_code(self):
  12. code_block = 'x= 123\n'
  13. new_block = auto_pep8.fix_code(code_block, os.getcwd())
  14. self.assertEqual(new_block, 'x = 123\n')