summaryrefslogtreecommitdiff
path: root/tests/extmod
AgeCommit message (Collapse)Author
2018-08-25Fix os.stat() to use 1970 epochNoralf Trønnes
Commit 95e70cd0ea6d 'time: Use 1970 epoch' changed epoch for the time module, but not for other users. This patch does the same for the only other core timeutils user: extmod/vfs_fat.c:fat_vfs_stat(). Other timeutils users: cc3200, esp8266 and stm32, are not changed. Ports that don't use long ints, will still get wrong time values from os.stat().
2018-07-11WIP: after merge; before testingDan Halbert
2018-06-18tests/extmod: Add test for ujson.dump writing to a user IOBase object.Damien George
2018-06-18tests/extmod/ujson_dump.py: Add test for dump to non-stream object.Damien George
2018-06-14Make Trinket M0 build fit; make RAMFS in vfs_fat_* tests be compliant with ↵Dan Halbert
expected API
2018-06-12tests/extmod: Add test for VFS and user-defined filesystem and files.Damien George
2018-06-06tests/extmod: Remove conditional import of uos_vfs, it no longer exists.Damien George
This conditional import was only used to get the tests working on the unix coverage build, which has now switched to use VFS by default so the uos module alone has the required functionality.
2018-06-06tests/extmod: Add test for importing a script from a user VFS.Damien George
2018-05-06tests: add new tests for uhashlib differencesJeff Epler
.. these tests currently fail, but a subsequent commit will fix them
2018-04-30tests: Add new tests for ubinascii differencesJeff Epler
.. some of these tests currently fail, but a subsequent commit will fix them.
2018-03-27Add VfsFat.label propertyJeff Epler
These allow accessing the filesystem label. For instance, in boot.py, you can set the label on the built-in storage with: storage.remount('/', False) storage.getmount('/').label = "NEWLABEL" storage.remount('/', True) Users with multiple CIRCUITPY boards may find it desirable to choose a different label for each board they own.
2018-03-23extmod/vfs_fat_file: Implement SEEK_CUR for non-zero offset.Ayke van Laethem
CPython doesn't allow SEEK_CUR with non-zero offset for files in text mode, and uPy inherited this behaviour for both text and binary files. It makes sense to provide full support for SEEK_CUR of binary-mode files in uPy, and to do this in a minimal way means also allowing to use SEEK_CUR with non-zero offsets on text-mode files. That seems to be a fair compromise.
2018-03-12extmod/vfs_fat: Add file size as 4th element of uos.ilistdir tuple.Tom Collins
2018-03-04tests/extmod/time_ms_us: Fix ticks tests, ticks_diff args are reversed.Damien George
2018-03-04tests/extmod/time_ms_us: Add test for calling ticks_cpu().Damien George
This is just to test that the function exists and returns some kind of valid value. Although this file is for testing ms/us functions, put the ticks_cpu() test here so not to add a new test file.
2018-02-28tests/extmod/vfs_fat_fileio1: Add test for calling file obj finaliser.Damien George
2018-02-26tests/extmod/uzlib_decompress: Add uzlib tests to improve coverage.Damien George
2018-02-26tests/extmod/vfs_fat_fileio1: Add test for failing alloc with finaliser.Damien George
2018-02-15extmod/modujson: Implement ujson.dump() function.Damien George
2018-01-31extmod/vfs_fat_file: Implement SEEK_CUR for non-zero offset.Ayke van Laethem
CPython doesn't allow SEEK_CUR with non-zero offset for files in text mode, and uPy inherited this behaviour for both text and binary files. It makes sense to provide full support for SEEK_CUR of binary-mode files in uPy, and to do this in a minimal way means also allowing to use SEEK_CUR with non-zero offsets on text-mode files. That seems to be a fair compromise.
2017-12-19tests/extmod: Add some uctypes tests to improve coverage of that module.Damien George
2017-12-19tests/extmod/uhashlib_sha256: Add test for hashing 56 bytes of data.Damien George
2017-12-14extmod/modframebuf: Add 8-bit greyscale format (GS8).Damien George
2017-12-14extmod/modframebuf: Add 2-bit color format (GS2_HMSB).Petr Viktorin
This format is used in 2-color LED matrices and in e-ink displays like SSD1606.
2017-12-12tests/extmod: Add test which subclasses framebuf.FrameBuffer.Damien George
2017-10-05tests/extmod: Add test for '-' in character class in regex.Damien George
2017-10-03tests/extmod: Add test for ure regexes leading to infinite recursion.Paul Sokolovsky
These now should be caught properly and lead to RuntimeError instead of crash.
2017-08-17extmod/modubinascii: Rewrite mod_binascii_a2b_base64.Alex Robbins
This implementation ignores invalid characters in the input. This allows it to decode the output of b2a_base64, and also mimics the behavior of CPython.
2017-07-20extmod/modussl_axtls: Allow to close ssl stream multiple times.Paul Sokolovsky
Make sure that 2nd close has no effect and operations on closed streams are handled properly.
2017-07-03extmod/modubinascii: Add check for empty buffer passed to hexlify.Damien George
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-01extmod/modure: If input string is bytes, return bytes results too.Paul Sokolovsky
This applies to match.group() and split(). For ARM Thumb2, this increased code size by 12 bytes.
2017-06-11tests/extmod/vfs_basic: Allow test to pass on embedded targets.Damien George
2017-06-10tests: Convert remaining "sys.exit()" to "raise SystemExit".Paul Sokolovsky
2017-06-07extmod/vfs: Allow to statvfs the root directory.Damien George
2017-05-13tests/extmod/vfs_fat_more: Make skippable is uos is not available.Paul Sokolovsky
Fixes Zephyr tests.
2017-05-13tests/extmod/vfs_fat: Add test for ilistdir of a non-existent directory.Damien George
2017-05-10tests/extmod/vfs: Update tests to reflect new ilistdir() method.Damien George
2017-05-09tests/extmod: Make some vfs tests fully unmount FSs before running.Damien George
Otherwise the existing FSs can interfere with the tests, and in some cases the tests can write to the real FS on the device.
2017-05-05tests/extmod: Add some more VFS tests.Damien George
2017-05-05tests/extmod: Add more tests for VFS FAT.Damien George
2017-04-21extmod/moductypes: Fix bigint handling for 32-bit ports.Paul Sokolovsky
2017-04-15extmod/machine_signal: Rename "inverted" arg to "invert", it's shorter.Damien George
A shorter name takes less code size, less room in scripts and is faster to type at the REPL. Tests and HW-API examples are updated to reflect the change.
2017-04-13tests/extmod/utimeq1: Improve coverage of utimeq module.Damien George
2017-04-04extmod/modframebuf: Make monochrome bitmap formats start with MONO_.Peter Hinch
MONO_xxx is much easier to read if you're not familiar with the code. MVLSB is deprecated but kept for backwards compatibility, for the time being. This patch also updates the associated docs and tests.
2017-04-03tests/extmod/vfs_fat_fileio*: Improve skippability.Paul Sokolovsky
Should be skipped on missing uso, uerrno modules.
2017-04-02tests: vfs_fat_fileio.py is too big to be parsed in 16K heap, split in 2.Paul Sokolovsky
This restores ability to run testsuite with 16K heap.
2017-03-20extmod/modframebuf: Add support for monochrome horizontal format.Peter Hinch
MHLSB and MHMSB formats are added to the framebuf module, which have 8 adjacent horizontal pixels represented in a single byte.
2017-03-14tests/extmod: Improve tinfgzip.c test coverage.Rami Ali
2017-03-14tests/extmod/vfs_basic: Unmount all existing devices before doing test.Damien George
This is so the test can run successfully on targets that already have something mounted.
2017-03-14tests/extmod: Improve re1.5/recursiveloop.c test coverage.Rami Ali