CMD + K

doctest-ignore-unicode

Community

Add flag to ignore unicode literal prefixes in doctests

Installation

To install this package, run one of the following:

Conda
$conda install magonser::doctest-ignore-unicode

Usage Tracking

0.1.2
1 / 8 versions selected
Downloads (Last 6 months): 0

Description

Overview

doctest-ignore-unicode is a plugin (currently only for Nose_) that adds a flag to ignore unicode literal prefixes in doctests.

.. _Nose: http://somethingaboutorange.com/mrl/projects/nose

The implmentation is inspired by https://github.com/nltk/nltk/blob/2and3/nltk/test/doctestnoseplugin.py

Usage

>>> def hello_world():
...     return 'Hello World'
>>> hello_world()  # doctest: +IGNORE_UNICODE
u'Hello World'

FAQ

Why?

If you need to ask you probably don't need it. (Hint: supporting python 2 & 3 in the same codebase).

About

Summary

Add flag to ignore unicode literal prefixes in doctests

Last Updated

Aug 12, 2017 at 14:02

License

Apache Software License

Supported Platforms

macOS-64