- When running `BUILD_IN_DOCKER=1 make -C tests/riotboot test`
new slot binaries (fw + hdr) need to be generated.
`%.bin: %.elf` is no defined when building in docker, so the
fw binaries $(SLOT_RIOT_ELFS:%.elf=%.bin) are added to
BUILD_FILES
The description states that the tests caused issues with an ancient
toolchain.
Building these tests locally worked fine.
So remove the obsolete BOARD_INSUFFICIENT_MEMORY lists.
Rather than dispatching the packet automatically once it is complete,
`gnrc_sixlowpan_frag_rb_add()` now only returns success, and leaves it
to the caller to dispatch the packet.
- BOARD_BLACKLIST has been used to blacklist boards with too little RAM/ROM
according to the comment
==> Moved those entries to BOARD_INSUFFICIENT_MEMORY instead
- pic32-clicker does build fine, so RAM/ROM efficiency has improved since
==> Dropped pic32-clicker from the list
First the comment does not fit these two boards and
second they would work compiler wise but just do not
have an SPI to support the radio. Hence, won't be
used due to missing features.
If the destination address or an address within the source route is
multicast within a RPL source routing header, a receiving node is
supposed to just discard the packets, but not to send an ICMPv6 error
message, as the test assumes at the moment.
Source: https://tools.ietf.org/html/rfc6554#section-4.2
Two Functions cmd_test_xtimer_mutex_lock_timeout_low_prio_thread and thread_low_prio_test are added.
This testfunction will test xtimer_mutex_lock_timeout with two threads (main thread and lower prio than main thread).
The main thread creates another thread and sleeps. While the main thread sleeps the other thread takes the mutex
and wakes the main thread up.
Then the main thread calls xtimer_mutex_lock_timeout and the second thread unlocks the mutex and
the main thread gets it and waits for the created thread to end.
Has test messages showing the thread count. To make sure the created thread ends.
(test messages may be removed in the future)
Adds a test case for when the following conditions cause a crash:
- a subsequent fragment is received before the first
- the reassembly buffer is currently filled up when another fragment of
a different datagram arrives and thus needs to be cached out to make
room for the new reassembly
Printing the 'Received ...' string takes a short while and it is possible
that data is received while the string is printed. It seems however that
NimBLE does not like to be without a mbuf ready for taking data while
receiving something, as this seems to lead to a memory leak somehow. Now
changing the order of actions inside the _on_data() function fixes this.
While looking at tests/gnrc_ipv6_ext_frag again while writing
RIOT-OS/Release-Specs#137, I noticed that several of tests that I
definitely wrote myself from scretch are attributed wrong (and
sometimes even documented wrong). I guess this was caused by just
copy-pasting the files...
The test application now correctly prints float value, with a 3 digits precision. The python test script now verifies the run time value printed for each test is following the x.xxx pattern.
This tests passing CFLAGS with spaces to an application and also that
even if the CFLAGS are defined after Makefile.include, they trigger
a rebuild when modified.
This includes an example how to pass macros with spaces to a docker
build.
The test as both an automated part for the CFLAGS with spaces, and a
manual part for the two other features.
- Decrease default stack size for pthread_cooperation and
cp11_condition_variable
- Reduce number of problems for thread cooperation and remove
from insufficient memory list
- make local functions / variables static
- adhere to the 80 column limit
- don't increment total if head could not be allocated
- allow to overwrite CHUNK_SIZE
A naive implementation may set a RTC alarm in 30s by calling
struct tm now;
rtc_get_time(&now);
now.tm_sec += 30;
rtc_set_alarm(&now, _cb, NULL);
This works for RTC implementations that use a RTT internally and call
mktime() to convert the struct tm to a unix timestamp, as mktime() will
normalize the struct in the process.
Call rtc_tm_normalize() when the RTC uses separate registers for time / date
components to ensure it is normalized.
This also modifies tests/periph_rtc to exercise this case.
The default channel configuration is managed within the Makefiles of many
examples and tests. This commit moves the default channel logic to
`makefiles/default-channel.ink.mk` to ease maintenance. All Makefiles that
previously managed the default channel configuration themself have been
updated to include that file.
The default channel configuration of the cc110x has been added
The test randomly fails on `native` due to timers being not accurate but
it cannot be otherwise. So better disable it than raising fake errors.
...
151 diff=3
150 diff=4
149 diff=3539
148 diff=4
147 diff=3
....
min/max error: 1/3539
too large difference.
Test Failed.
Timeout in expect script at "child.expect_exact("Test complete.")"
(tests/xtimer_periodic_wakeup/tests/01-run.py:22)
The test randomly fails on `native` due to timers being not accurate but
it cannot be otherwise. So better disable it than raising fake errors.
main(): This is RIOT! (Version: buildtest)
Testing generic evtimer
This should list 2 items
ev #1 offset=1000
ev #2 offset=500
This should list 4 items
ev #1 offset=659
ev #2 offset=341
ev #3 offset=500
ev #4 offset=2454
Are the reception times of all 4 msgs close to the supposed values?
At 662 ms received msg 0: "#2 supposed to be 659"
At 1009 ms received msg 1: "#0 supposed to be 1000"
At 1511 ms received msg 2: "#1 supposed to be 1500"
Traceback (most recent call last):
File "/tmp/dwq.0.3125418833043728/ef3af88c4b3615788b164464a437df5c/tests/evtimer_msg/tests/01-run.py", line 33, in <module>
sys.exit(run(testfunc))
File "/tmp/dwq.0.3125418833043728/ef3af88c4b3615788b164464a437df5c/dist/pythonlibs/testrunner/__init__.py", line 29, in run
testfunc(child)
File "/tmp/dwq.0.3125418833043728/ef3af88c4b3615788b164464a437df5c/tests/evtimer_msg/tests/01-run.py", line 26, in testfunc
assert(actual in range(expected - ACCEPTED_ERROR, expected + ACCEPTED_ERROR))
AssertionError
The warning issued when the PID and VID are set to the default values should
not be printed on `make clean` and other targets, only with `make all` and it
should be a proper target.
To do: replace shell echos with proper $(warning ..) calls.
Add make only function to convert strings to lowercase and uppercase.
This can replace the `$(shell echo $(var) | tr 'a-z-' 'A-Z_')` pattern.
Using the 'make' implementation results in being around 100 times faster.
Check the interaction with a board through make term.
It is using a shell without echo or prompt for reference.
It currently checks that there is no local echo.
Rename TMP006 to TMP00x
Add TMP007 sensor support to TMP00X
Change uint8_t reg to uint16_t
Add to doxygen documentation group
Expose compile time configurations
Move defines from .c to .h
Change double to float, because double is not needed
Add TMP007 register information
This moves 'unittests/tests-cpp_ctors' to its own test.
It prevents requiring 'cpp' in the 'unittests' that forced almost all
architectures to link the unittests with `g++`.
It also removes the need to have disabled tests for architectures.
Some boards were actually not big enough to compile unittests.
But were hidden by the 'cpp' missing feature.
Blacklist boards that were disabled for cpp test even though they
provide the 'cpp' feature.
* use names with RFC
* add terminating comma
* remove newlines between tests values
This prepares for the format of the next commit adding all RFC tests.
This will reduce the number of changes in upcoming commit.
The test assumes that 'printf/puts' are non interruptible operations.
Use a mutex to guarantee it.
Without this, the automated test was failing in some configurations with
lines being cut by others.
Reduce the amount of tested values by a 100.
This makes the testing time go from 3 minutes to 2 seconds on
`frdm-kw41z`.
Testing that the integer calculation matches the float one does not need
to be performed on the full range on boards. Checking some values should
be enough to detect overflow issues.
The full range checking is kept on native.
The test fails on both murdock and on my machine due to the process
exiting directly.
pexpect.exceptions.EOF: End Of File (EOF). Exception style platform.
HACK, the test currently fails in CI for `native` due to `utf-8` handling.
HACK, the test implementation can fail due being de-scheduled during printf.
The test application provides:
- RIOT's basic network utilities such as `ping6`
- A custom `cc110x` shell command that can be used print the low level device
and driver state. This is mostly useful for debugging.
- Removed cc110x driver
- Updated all makefiles
- Kept both board specific configurations and support for it in RIOT's
upper layers, so re-implementations don't need to start from zero
Python dictionaries are not guaranteed to be ordered until version
3.7. In 3.6 they are ordered too, but that is an implementation
detail. riotdocker seems to be using 3.5.
As it stands now, it would not be a problem if the test commands
are run in a random order, except that:
- It would result in non-reproduceable tests.
- It hinders testing other functionality, such as exiting the shell.
For test scripts, a terminal that does not modify the input and output
streams, configured without local echo, is preferred as it ensures the
test setup is introducing as little noise as possible.
Use test_utils_interactive_sync for synchronizing some case treat
the output before `reset` as the start of the test,
which fails for some boards/configurations.
Remove unconditionally setting 'BOARD' to an hardwritten value.
The definition must be moved before including 'Makefile.tests_common' as
it defines 'BOARD ?= native'.
Changes the test so that EVENT_QUEUE_INIT_DETACHED is used for the initialization of detached event queue. Without this change, a compilation problem was not recognized for ESP8266, MSP430 and MIPS.
Previously this was not tested and excepted KERNEL_PID_UNDEF == 0 as
legal value for received `gnrc_netif_hdr`s (which except for the
loopback interface is wrong)
The evtimer_msg test is expanded to also delete entries.
Furthermore the messages that are printed should now show
numbers that are very close (if not equal). Something like
this:
At 740 ms received msg 0: "#2 supposed to be 740"
At 1081 ms received msg 1: "#0 supposed to be 1081"
At 1581 ms received msg 2: "#1 supposed to be 1581"
At 4035 ms received msg 3: "#3 supposed to be 4035"
The function evtimer_print is also called to show the
intermediate status of evtimer entries.
The mips-malta board is a maintainance burden, has no working UART input
and is unobtainable and thus must be removed.
1. Unobtainable board
=====================
The mips-malta board is not an off-the-shelf part. A quick web
search only show the MIPS website where one is told to "contact sales".
I could find it on ebay, used, at €155 and from single seller.
Not having access to the board means:
a. We cannot maintain it. In fact it could be broken right now.
b. Potential RIOT uses have not access to the board either. In other
words, it is pointless to run on hardware nobody has.
2. No working UART input
========================
Not all applications need UART input, but that is no excuse for not supporting
it:
a. Makes development & debugging way harder.
b. It is impossible to run interactive tests.
b.1. Constrains the rest of the platforms by providing an incentive to not
make tests interactive.
c. The lack of UART is a witness to the poor quality of the port.
I want to stress point (c). If something as basic as a serial port cannot work,
how can we expect more complex fucntionality to work. The answer is impossible
to know, because of point (1).
3. Maintainance burden
======================
The RIOT project has limited time and human resources which can be better spent.
a. Compiling for mips-malta wastes CPU time.
b. Blacklisting the board in the test wastes contributor's time.
c. Adapting the board's makefile during build system rework takes time and makes
the reworks harder.
c.1. Add to that that the changes are most of the time not even tested on the board
because of (1). Look at the github issues/PRs and you will see it.
d. Developers usually stick to the lowest common denominator. Issue (2) sets this
denominator unacceptably low.
MIPS platform in general
========================
In commits I will address general issues in the MIPS platform and why it should all
be removed.
Adding saml1[01]-xpro, nucleo-f302r8|f334r8 to
BOARDS_INSUFFICIENT_MEMORY.
The riotboot build fails because it only offers half the flash size (per
slot), compared to before where the default build would not use riotboot
at all, thus have double the flash (but being useless).
... if the riotboot feature is used.
Previously, even an application that had "FEATURES_REQUIRED += riotboot"
set would still flash the non-riotboot binary on "make flash".
This is usualy not what the user wants.
This commit set's the FLASHFILE variable to the combined "riotboot
bootloader + slot0 + empty slot1" binary. This has the effect that make
all, flash and flash-only will compile and/or flash a working riotboot
setup.
tests/riotboot and tests/riotboot_flashwrite now default to flashing the
riotboot-extended binary. tests/riotboot was previously configured to
use the riotboot-combined binary. This has been changed in order to not
behave differently than how usual riotboot applications do.
When subscribing to IPv6 packets on a router for sniffing, the NETIF
header is released prematurely, because of a wrong
`gnrc_pktbuf_start_write()` call. This test aims to reproduce this
error case.
Summary for Users
=================
Deprecation is scheduled for 2020.01.
Users which depend on this module and cannot switch libraries may copy
the code into to their own application.
As expressed in PR #11724, the UBJSON module has issues which are not easy
or worth fixing.
Before removing the module, it should be marked as deprecated to give users
time to either migrate to another library, or copy the code to their own
private repo.
The deprecation warning has been supressed from the unit tests. This has the
ugly side-effect of supressing deprecation warning in other unit tests too,
but that should not last long, only until the module is finally deleted.
Blacklist native for the xtimer tests that have timing issues.
This also enables running the test on `nrf52dk` as I think it was
forgotten when adding the support.
New test function cmd_test_xtimer_mutex_lock_timeout_long_locked.
In this test the mutex is locked and the timeout is long.
When it works the thread continues running and stops waiting for the mutex and
the function will return that it did not get the mutex.
Adding a first normal test case where the mutex is unlocked and the timeout is long.
The timer will not trigger in this test and instead wil be removed after getting the mutex.