Damien George
04552ff71b
py: Implement raising a big-int to a negative power.
...
Before this patch raising a big-int to a negative power would just return
0. Now it returns a floating-point number with the correct value.
2017-07-25 11:49:22 +10:00
Tom Collins
6cfe737597
tests/basics/builtin_exec: Test various globals/locals args to exec().
2017-07-21 15:17:33 +10:00
Damien George
6c1b7e008d
tests: Rename exec1.py to builtin_exec.py.
2017-07-21 15:11:24 +10:00
Paul Sokolovsky
4368ae3142
extmod/modussl_axtls: Allow to close ssl stream multiple times.
...
Make sure that 2nd close has no effect and operations on closed streams
are handled properly.
2017-07-20 00:20:53 +03:00
Damien George
761e4c7ff6
all: Remove trailing spaces, per coding conventions.
2017-07-19 13:12:10 +10:00
Paul Sokolovsky
ad3abcd324
tests/cpydiff: Add case for str.ljust/rjust.
2017-07-09 15:04:26 +03:00
Paul Sokolovsky
0c5369a1f0
tests/cpydiff/: Improve wording, add more workarounds.
2017-07-09 14:33:55 +03:00
Paul Sokolovsky
5f65ad8c96
tests/cpydiff/core_class_supermultiple: Same cause as core_class_mro.
2017-07-09 13:47:23 +03:00
Paul Sokolovsky
c5efb8159f
tests/cpydiff/core_arguments: Move under Functions subsection.
...
This is the last "orphan" case.
2017-07-09 13:36:28 +03:00
Paul Sokolovsky
b2979023ac
tests/cpydiff/core_class_mro: Move under Classes, add workaround.
2017-07-09 13:32:17 +03:00
Damien George
f69ab79ec8
py/objgenerator: Allow to hash generators and generator instances.
...
Adds nothing to the code size, since it uses existing empty slots in the
type structures.
2017-07-07 11:47:38 +10:00
Paul Sokolovsky
ed52955c6b
tests/cpydiff/modules_deque: Elaborate workaround.
2017-07-05 23:03:37 +03:00
Krzysztof Blazewicz
7feb7301b2
tests/basics: Add tests for arithmetic operators precedence.
2017-07-05 15:51:03 +10:00
Damien George
6b8b56f859
py/modmath: Check for zero division in log with 2 args.
2017-07-04 02:15:11 +10:00
Damien George
b86c65d31c
extmod/modubinascii: Add check for empty buffer passed to hexlify.
...
Previous to this patch hexlify(b'', b':') would lead to a bad crash due to
the computed length of the result being -1=0xffffffff.
2017-07-03 14:52:00 +10:00
Paul Sokolovsky
58b7b01cb5
extmod/modure: If input string is bytes, return bytes results too.
...
This applies to match.group() and split().
For ARM Thumb2, this increased code size by 12 bytes.
2017-07-01 01:25:45 +03:00
Damien George
369e7fd178
tests/unix/extra_coverage: Add test for mp_vprintf with bad fmt spec.
2017-06-30 12:25:42 +10:00
Damien George
8f6ef8de48
tests/basics/namedtuple1: Add test for creating with pos and kw args.
2017-06-29 17:50:09 +10:00
Damien George
409fc8f9c1
tests/import: Update comment now that uPy raises correct exception.
2017-06-28 12:21:29 +10:00
Damien George
3a9445c6b3
tests/import: Add a test for the builtin __import__ function.
2017-06-28 12:21:29 +10:00
Damien George
4a6c0fda78
tests: Auto detect floating point capabilites of the target.
...
The floating-point precision of the target is detected (0, 30, 32 or 64)
and only those tests which can run on the target will be run.
2017-06-26 13:47:00 +10:00
Paul Sokolovsky
bc7659eb59
tests/connect_nonblock: Refactor towards real net_hosted test.
...
In the future, a special runner for such tests will import each test and
call test() function with an address of test server to use.
2017-06-23 21:27:05 +03:00
Paul Sokolovsky
3f9d59c87a
tests/net_inet: Move tests which don't require full Internet to net_hosted.
...
The idea is that these tests can be run with just a test server running
on a test host, with device under test connecting to it, instead of
requiring Internet connection for testing.
Such setup is however WIP, and some tests in net_hosted/ are so far
written to connect to Internet, as there're not test server written
yet. This is expected to evolve over time.
2017-06-23 21:12:32 +03:00
Damien George
44922934f5
tests/basics: Add tests for for-else statement.
2017-06-22 14:02:14 +10:00
Damien George
458cbacb8f
tests/net_inet: Add tests for accept and connect in nonblocking mode.
...
Some of these tests don't require an Internet connection, but here is a
good place to put them for now.
2017-06-21 12:25:10 +10:00