Commit Graph

15 Commits (ec789513dce9b072a512deb6628375e88b84026b)

Author SHA1 Message Date
David Wilson 30d933b299 issue #477: remove unused pytest bits from importer_test. 6 years ago
David Wilson e9706a4a09 issue #477: _update_linecache() must append newlines. 6 years ago
David Wilson cbcd8267d1 tests: must decode() zlib result for 3.x. 6 years ago
David Wilson 410016ff47 Initial Python 3.x port work.
* ansible: use unicode_literals everywhere since it only needs to be
  compatible back to 2.6.
* compat/collections.py: delete this entirely and rip out the parts of
  functools that require it.
* Introduce serializable Kwargs dict subclass that translates keys to
  Unicode on instantiation.
* enable_debug_logging() must set _v/_vv globals.
* cStringIO does not exist in 3.x.
* Treat IOLogger and LogForwarder input as latin-1.
* Avoid ResourceWarnings in first stage by explicitly closing fps.
* Fix preamble_size.py syntax errors.
6 years ago
David Wilson 03fcf057dd tests: just call log_to_file() from testlib
Now we can run test.sh with MITOGEN_LOG_LEVEL=debug and things just
work.
7 years ago
David Wilson 23e279b617 tests: get import_test limping back to health. 7 years ago
Alex Willmer 4b373c421b core: Standardise type of Importer.whitelist
This seemed a reasonable streamlining, but I'm happy to be overruled.
7 years ago
Alex Willmer 8338caa419 tests: Add mitogen.core.is_blacklisted_import() tests
These test the current behviour, which may not be exactly the intended
behaviour. Refs #98
7 years ago
Alex Willmer 9ccff0f5d1 Fix TypeError while initiliazing ImporterMixin
Since f44356af32 mitogen.core.Importer()
takes a Router instance.
7 years ago
Alex Willmer 7e01c5bed5 Import and use unittest2 without aliasing it 7 years ago
Alex Willmer e8e023ce59 Use specific TestCase assertions throughout tests
e.g. assert x == y -> self.assertEqual(x, y);
self.assertTrue(isinstance(x, y)) -> self.assertIsInstance(x, y)

These specific methods give more useful errors in the case of a test
failure.
7 years ago
Alex Willmer 17da6e9998 Use unittest2 in all tests
This allows using features such as TestCase,assertIsInstance on Python
2.6 and earlier.
7 years ago
David Wilson d17af194b5 Fix importer_test constructor signature. 7 years ago
David Wilson ced6d8e404 Fix up importer_test. 7 years ago
David Wilson e7ff6259a3 Initial commit. 7 years ago