TST: test_umath: fix wrong indent in test_fast_power

Also, use assert_ instead of assert
fix undefined function and add integer divisions
2to3: Replace xrange by range and use list(range(...)) where needed

In python3 range is an iterator and `xrange` has been removed. This has
two consequence for code:

    1) Where a list is needed `list(range(...))` must be used.
    2) `xrange` must be replaced by `range`

Both of these changes also work in python2 and this patch makes both.

There are three places fixed that do not need it, but I left them in
so that the result would be `xrange` clean.

Closes #3092
BUG: Rebased tools/py3tool.py was missing `,` in list.
Merge pull request #3141 from ewmoore/test_fast_power

TST: test_umath: fix wrong indent in test_fast_power
Merge pull request #3168 from juliantaylor/numarray-fixes

fix undefined function and add integer divisions
Merge pull request #3122 from charris/2to3-apply-xrange-fixer

2to3: Replace xrange by range and use list(range(...)) where needed
MAINT: Fix python3 ResourceWarning when running test_exec_command.py

The tests in test_exec_command.py used with blocks with a context
manager that could redirect stderr and stdout to temporary files but
those files were not closed on exit from the block.
Merge pull request #3179 from charris/fix-resource-warning

MAINT: Fix python3 ResourceWarning when running test_exec_command.py