Commit Graph

818 Commits

Author SHA1 Message Date
Sebastian Huber
c96644e873 libtest: Print SHA256 hash in base64url 2021-02-26 09:10:09 +01:00
Sebastian Huber
74eff26c1d libtest: Report target hash
Update #4267.
2021-02-26 09:10:09 +01:00
G S Niteesh Babu
f867e7b6f4 libtests/ofw01: Added a test for RTEMS OFW
This commit adds a basic test that tests all the implemented
RTEMS OFW functions.
2020-12-27 10:05:09 +01:00
Sebastian Huber
eae22cc03e libtest: Make test case allocator configurable 2020-11-19 08:39:02 +01:00
Frank Kühndel
0007d65f72 testsuits/dl10 : Prototype missing
Fix a compiler warning about a missing prototype.

If you wonder why the function name is not `static`:
The code in the file only serves a test where the dynamic object loader
(aka dlopen()) should handle duplicated symbols in an archive.

testsuites/libtests/dl10/dl10-o6.c:14:5: warning: no previous prototype
for 'rtems_main_o5' [-Wmissing-prototypes]
       14 | int rtems_main_o5 (void)
          |     ^~~~~~~~~~~~~
2020-10-10 15:03:14 +02:00
Chris Johns
558a19d3ad testsuite/rcxx01: Add examples for use in the User manual 2020-10-09 16:45:24 +11:00
Chris Johns
cf95826089 cpukit/librcxx: Add a C++ thread interface with attributes 2020-10-08 11:01:59 +11:00
Sebastian Huber
2da7e94fe5 libtests/sha: Fix test if -O0 is used 2020-09-30 13:01:45 +02:00
Sebastian Huber
4647789820 irqs01/smpirqs01: New tests
Close #4034.
2020-09-14 07:11:40 +02:00
Sebastian Huber
c728948434 libtest: Add T_push_plan() and T_pop_plan()
Update #3199.
2020-08-18 07:08:51 +02:00
Sebastian Huber
72960bc7d4 libtest: Change T_step() and T_assert_step()
Normally, the expected test step must be a compile time constant.  Allow
variable expected test steps for the T_step() and T_assert_step().  This
can be used for parameterized test loops with individual fixtures.

Remove the ability to use custom failure messages due to some
implementation constraints.

Update #3199.
2020-08-18 07:08:51 +02:00
Sebastian Huber
5383d4db04 libtest: Add fixture steps
Support a new test plan for each nested fixture.

Update #3199.
2020-08-18 07:08:51 +02:00
Sebastian Huber
5a8114c6c5 libtest: Change fixture scope method
Return the produced character count.  There is no need for a NUL
termination.

Update #3199.
2020-08-18 07:08:51 +02:00
Aschref Ben Thabet
5d7ab6bd21 libtests/dl10: Delete unused functions 2020-08-11 09:49:02 +02:00
Sebastian Huber
c1354f0514 libtest: Add T_thread_switch_record()
Add support to record thread switch events.  This can be used to check
that a blocking operation results in the expected sequence of thread
switches.

Update #3199.
2020-08-11 08:03:47 +02:00
Sebastian Huber
32f1f747cc libtest: Fix T_interrupt_test() in SMP configs
Update #3199.
2020-08-06 19:15:57 +02:00
Sebastian Huber
cc3fd8fcf1 libtest: Add T_interrupt_test()
Update #3199.
2020-07-23 09:27:47 +02:00
Sebastian Huber
d702c9f47d libtest: Make check message optional
This macro magic is in line with C11 and C++11, but limits the maximum
count of arguments.

Update #3199.
2020-07-23 09:27:47 +02:00
Sebastian Huber
cb3c6bdc0f libtest: Add push/pop fixture support
Update #3199.
2020-07-23 09:27:47 +02:00
Sebastian Huber
6b27e3251e libtest: Support custom scope messages via fixture
Update #3199.
2020-07-23 09:27:47 +02:00
Sebastian Huber
361404e87d libtest: Move <t.h> to <rtems/test.h>
Update #3199.
2020-07-23 09:27:45 +02:00
Sebastian Huber
9de8d61a9a libtest: <rtems/test.h> to <rtems/test-info.h>
Rename this header file to later move <t.h> to <rtems/test.h>.  The main
feature provided by <rtems/test-info.h> is the output of standard test
information which is consumed by the RTEMS Tester.

Update #3199.
2020-07-23 09:27:10 +02:00
Sebastian Huber
ea2d9237fc libtests/tar01: Remove files of tar01.tar archive
Update #3968.
2020-05-08 15:12:40 +02:00
Sebastian Huber
ef9517b7d5 libtests/tar0[12]: Add tar archive
Do not generate the test tar archive on the host computer since not all
file systems support symbolic links.

Close #3968.
2020-05-07 12:31:56 +02:00
Chris Johns
e78c0806cb libtest/dl09: Test trampolines only when supported 2020-05-06 08:46:57 +10:00
Chris Johns
3f50e8e671 testsuite/dl06: Add a local define to control tracing
Closes #3969
2020-05-05 15:00:45 +10:00
Sebastian Huber
a8f0d941c3 libtests/heapwalk: Fix for RTEMS_DEBUG
Update #2962.
2020-04-29 06:58:16 +02:00
Sebastian Huber
80cf60efec Canonicalize config.h include
Use the following variant which was already used by most source files:

  #ifdef HAVE_CONFIG_H
  #include "config.h"
  #endif
2020-04-16 07:30:00 +02:00
Chris Johns
d007cc2cee libmisc/shell: Fix the handling of joel scripts in telnet
- Fix the passing of std[in/out] to child threads
- Fix deleting of managed memory in the key destructor
- Only set the key in the main loop thread
- Only allocate a shell env outside of the main loop
- Fix memory leak if the task start fails
- Remove error level from shell env, it cannot be returned this way. Add
  exit_code but the API is broken so it cannot be returned.

Closes #3859
2020-04-15 08:30:30 +10:00
Sebastian Huber
8b8c068df3 testsuites: Remove CONFIGURE_MALLOC_STATISTICS
This configuration option is obsolete since 2014.

Update #1367.
2020-03-31 15:21:58 +02:00
Sebastian Huber
ab42b3e100 record: Add rtems_record_dump()
Add rtems_record_dump_base64() and rtems_record_dump_base64_zlib().

Add CONFIGURE_RECORD_FATAL_DUMP_BASE64 and
CONFIGURE_RECORD_FATAL_DUMP_BASE64_ZLIB configuration options.

Update #3904.
2020-03-18 07:20:52 +01:00
Sebastian Huber
0161b93d50 imfs: Replace devfs with an IMFS specialization
Add a simplified path evaluation function IMFS_eval_path_devfs() for a
device only IMFS configuration.

The code size can be further reduced by the application if it disables
the support for legacy IO drivers via:

  #define CONFIGURE_IMFS_DISABLE_MKNOD
  #define CONFIGURE_IMFS_DISABLE_MKNOD_DEVICE

Obsolete CONFIGURE_MAXIMUM_DEVICES.  Remove BSP_MAXIMUM_DEVICES.

Update #3894.
Update #3898.
2020-03-09 17:26:54 +01:00
Sebastian Huber
c7f748a100 config: Remove CONFIGURE_DISABLE_SMP_CONFIGURATION
The CONFIGURE_DISABLE_SMP_CONFIGURATION configuration option and
rtems_configuration_is_smp_enabled() were added during the SMP support
development cycle as a workaround to fix some testsuite failures in SMP
configurations.  All use cases were replaced with tests for specific
conditions.  The configuration option and test macro were undocumented.

Close #3876.
2020-02-25 07:18:36 +01:00
Sebastian Huber
ba74ebde74 libio: Add POSIX user environment pointer to TCB
The IO library used a POSIX key to store an optional POSIX user
environment pointer.  This pulled in the POSIX keys support in every
application configuration.  Add a user environment pointer to the thread
control block (TCB) instead.  Applications which do not need the POSIX
user environment will just get an overhead of one pointer per thread.

Close #3882.
2020-02-25 07:18:26 +01:00
Sebastian Huber
5d1d3485cb libtests/stackchk: Include missing header file
Update #3875.
2020-02-25 07:15:17 +01:00
Chris Johns
3f7ebddfa4 testsuite/newlib: Check newlib does not touch an assigned std FILE pointer
Update #3870
2020-02-18 08:47:47 +11:00
Sebastian Huber
ccaec9661f libtests/malloc04: Fix typo
Update #3838.
2020-02-04 11:25:45 +01:00
Sebastian Huber
eea21eaca1 bsps: Rework work area initialization
The work area initialization was done by the BSP through
bsp_work_area_initialize(). This approach predated the system
initialization through the system initialization linker set. The
workspace and C program heap were unconditionally initialized.  The aim
is to support RTEMS application configurations which do not need the
workspace and C program heap.  In these configurations, the workspace
and C prgram heap should not get initialized.

Change all bsp_work_area_initialize() to implement _Memory_Get()
instead.  Move the dirty memory, sbrk(), per-CPU data, workspace, and
malloc() heap initialization into separate system initialization steps.
This makes it also easier to test the individual initialization steps.

This change adds a dependency to _Heap_Extend() to all BSPs.  This
dependency will be removed in a follow up change.

Update #3838.
2020-02-04 06:06:41 +01:00
Sebastian Huber
556e45f24b libtest: Add T_check_task_context() action 2019-12-20 11:06:13 +01:00
Sebastian Huber
77ac1519e8 libtest: Use test configuration in T_now()
Use the user provided now handler of the test configuration to get the
time in T_now().
2019-12-20 11:06:13 +01:00
Sebastian Huber
3cec2dfbc4 config: CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS
Rename CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS into
CONFIGURE_MAXIMUM_FILE_DESCRIPTORS.

Update #3753.
2019-12-19 08:53:03 +01:00
Sebastian Huber
d0b704b09c libtest: Change expected pass state string
Use separator character '_' for all test states.
2019-12-05 07:10:59 +01:00
Sebastian Huber
a6879a418d testsuites: Remove rtems_test_pause*()
The rtems_test_pause() and rtems_test_pause_and_screen_number() macros
had different implementations depending on the RTEMS_TEST_NO_PAUSE
define.  This define was defined to 1 by default.  The user was able to
change this via the undocumented --disable-test-no-pause configure
command line option.

Pausing tests and waiting for user input contradicts the goal of having
automated test runs.  Remove this feature.

Update #3818.
2019-12-04 07:40:32 +01:00
Sebastian Huber
4551f5f0db untar: Properly make parent path
Close #3823.
2019-11-26 08:10:27 +01:00
Sebastian Huber
4a056523cf libtests/dl*: Rename source files
Rename source files to use a %.c -> %.o and %.cc -> %.o pattern.  Use
*.cc for C++ source files instead of *.cpp to be in line with other C++
source files.

Update #3818.
2019-11-26 07:21:44 +01:00
Sebastian Huber
b8b954a3e9 libtests/dl*: Use rtems_tarfs_load()
Use rtems_tarfs_load() instead of Untar_FromMemory() to reduce the
memory demands of the tests.
2019-11-26 07:21:44 +01:00
Sebastian Huber
5c2e7104e7 libtests: Use '-' for TAR file names
Use uniform pattern for all TAR file names.  Use the dl* tests as a
template.

Update #3818.
2019-11-25 13:01:54 +01:00
Sebastian Huber
8f021bdbf9 libtests/dl*: Do not generate files via "echo"
Add the static files to the repository.  This simplifies the build.

Update #3818.
2019-11-25 11:32:19 +01:00
Sebastian Huber
273e8b72c8 libtests/tar0[12]:: Use static archive content
This simplifies the build process.  Do not generate the archive content
through the build system.  Let the version control system deal with
symbolic links.

Update #3818.
2019-11-25 11:32:19 +01:00
Hesham Almatary
1a95dd738f testsuite: Only include termios10/termios11 tests if compiled with POSIX
Both need POSIX support
2019-11-21 10:32:46 +00:00