Commit Graph

260 Commits

Author SHA1 Message Date
田昕
c427f408cb testing:add MTD Fail-safe config-data tests
Signed-off-by: 田昕 <tianxin7@xiaomi.com>
2022-08-31 20:33:20 +08:00
Huang Qi
2e2630e838 Don't download tarballs if a local git repo found
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-08-28 17:20:47 +08:00
Masayuki Ishikawa
1bf462e1c1 testing: getprime: Fix the thread number info
Summary:
- I noticed that getprime sometimes shows a wrong thread number
- This commit fixes this issue

Impact:
- None

Testing:
- Tested with sabre-6quad:netnsh

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2022-08-25 19:42:25 +08:00
pengyiqiang
a9f6d66888 add fds initialization and buttonset comparison 2022-08-17 11:41:13 +08:00
pengyiqiang
d3232585b0 fixed non-standard naming and usage 2022-08-17 11:41:13 +08:00
pengyiqiang
2af0fb3815 fix warning 2022-08-17 11:41:13 +08:00
pengyiqiang
2ed3a91426 testing: add monkey test 2022-08-17 11:41:13 +08:00
liuhaitao
e1a382d62a testing/uclibcxx_test: Define TESTDIR correctly
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-16 19:00:01 +03:00
Xiang Xiao
79e4c66764 testing/sensortest: Keep g_sensor_info in order
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-15 10:49:34 +03:00
Xiang Xiao
3021b8d11e testing/sensortest: Add FAR for pointer type
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-15 10:49:34 +03:00
xiatian6
491f549d1c fix: sensor: add sensor type of cap
Increase the type of cap sensor, including
raw data and detection status.

Signed-off-by: xiatian6 <xiatian6@xiaomi.com>
2022-08-15 10:49:34 +03:00
Xiang Xiao
b515a00fea zmodem: Move crc16.h and crc32.h from host to host/nuttx
to avoid the conflict with the 3rd party library

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-08-13 13:28:30 +03:00
Jiuzhu Dong
e04333c986 driver/sensor: rename /dev/sensor -> /dev/uorb
because this directory contains all topics by uorb using, not just sensors.

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-08-08 23:11:37 +08:00
Lee Lup Yuen
8b43f9f9ca testing/sensortest: Update device path
Device paths are now named `/dev/sensor/sensor_...`: 3fdd036ba6/drivers/sensors/sensor.c (L49)
2022-08-08 13:31:18 +08:00
Jiuzhu Dong
eef03ad0a1 testing/sensortest: fix cmd argument mismatch(follow new sensor driver)
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-29 16:26:40 +03:00
Jiuzhu Dong
45f2c2a26d testing/sensortest: fix compile break
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-26 12:38:34 +08:00
Jiuzhu Dong
a06fa5ac27 testing/sensor_test: update sensortest according to enhance sensor driver
1.update prefix of sensor event structure to sensor_xxx.
2.remove activate cmd because of open will auto activate sensor.

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-07-26 10:40:39 +08:00
Xiang Xiao
a549ea3888 Fix find: '/github/workspace/sources/nuttx/libs/libxx/uClibc++/tests': No such file or directory
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-07-25 10:47:21 +02:00
Fotis Panagiotopoulos
c4c3ffff90 ostest: Fixed prints in setenv test. 2022-07-20 11:57:01 +08:00
chenwen@espressif.com
068905d07b testing/irtest: Fix issue of failure to open multiple IR devices
Signed-off-by: chenwen@espressif.com <chenwen@espressif.com>
2022-06-14 14:56:18 +02:00
anjiahao
99629e9b5f fstest:support fstest can run many times
Signed-off-by: anjiahao <anjiahao@xiaomi.com>
2022-06-04 01:14:37 +08:00
Xiang Xiao
26367a66db testing/ostest: Replace up_tls_info with tls_get_info
follow the kernel side change

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-05-30 15:14:29 +03:00
David Sidrane
3821121a2e ostest:priority_inheritance Added priority restoration test 2022-05-21 18:27:55 +03:00
chao.an
e4dcdcd158 testing/ostest: remove CONFIG_TESTING_OSTEST_FPUSIZE
fptest should not need to care about the size of FPU

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-04-19 02:48:24 +08:00
Xiang Xiao
3760ab5fc8 Remove the unneeded void cast
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-04-17 23:31:35 +03:00
Jiuzhu Dong
5b0b44f24e iozone: support on nuttx
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-04-07 02:51:49 +08:00
YAMAMOTO Takashi
fe5b68142e testing/mm: Test more patterns for memalign 2022-04-07 02:51:39 +08:00
YAMAMOTO Takashi
f9a24e3c0a testing/mm: check alignment in do_memaligns 2022-04-07 02:51:39 +08:00
YAMAMOTO Takashi
cc5f73019e testing/mm: Update after the recent changes in nuttx
The following commit changed the typo of SIZEOF_MM_ALLOCNODE
from int to size_t.
```
commit 39eaeefb78f36724adbdc47400d6f60372b68344
Author: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
Date:   Thu Jan 27 12:17:20 2022 +0800

    mm/mm_heap: remove the unnecessary check for memory node size

    Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>

```
2022-04-07 02:51:39 +08:00
wangbowen6
c7b7162d5f testing/mm: add memory boundary realloc test.
Signed-off-by: wangbowen6 <wangbowen6@xiaomi.com>
2022-04-02 18:11:58 +08:00
wangbowen6
963c1f31db testing/mm: repair the memory leak question when realloc failed.
Signed-off-by: wangbowen6 <wangbowen6@xiaomi.com>
2022-03-31 03:16:24 +08:00
Gustavo Henrique Nihei
c29deef4e5 testing: Extend cxxtest with some C++17 features
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-03-29 10:03:10 +08:00
Jiuzhu Dong
5fab48a2fe testing/scanftest: fix nxstyle
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-03-28 00:25:56 +08:00
Jiuzhu Dong
494b47c692 fix compile warning
scanftest_main.c:1121:34: warning: ‘%s’ directive writing up to 2 bytes into a region of size between 1 and 80 [-Wformat-overflow=]
canftest_main.c: In function 'scanftest_main':
scanftest_main.c:1399:42: warning: format '%n' expects argument of type 'int *', but argument 3 has type 'unsigned int' [-Wformat=]
 1399 |               printf("Test #%u assigned %nou instead of %lli.\n",
      |                                         ~^
      |                                          |
      |                                          int *
      |                                         %d
 1400 |                      t + 1, nou, type_data[t].value.u);
      |                             ~~~
      |                             |
      |                             unsigned int

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-03-28 00:25:56 +08:00
Gustavo Henrique Nihei
732df52aef testing: Fix cxxtest application for "no-rtti" builds
Signed-off-by: Gustavo Henrique Nihei <gustavo.nihei@espressif.com>
2022-03-26 06:31:51 +02:00
Petro Karashchenko
566be8c7b1 definitions: unify MAX and MIN macro definitions
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2022-03-16 23:20:17 +08:00
fanzhuyun
2dde296d4f testing/fstest: add cleanup to fatutf8
Signed-off-by: fanzhuyun <fanzhuyun@xiaomi.com>
2022-03-15 18:38:52 +08:00
caofuqi1
4756f33d70 apps: testing: uclibcxx_test: add uclibcxx_test Kconfig
Signed-off-by: caofuqi1 <caofuqi1@xiaomi.com>
2022-03-15 01:36:02 +08:00
Alin Jerpelea
e0499fea49 apps: testing: ostest: nxstyle fixes
fixes for errors reported by nxstyle

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-03-08 01:44:49 +08:00
Alin Jerpelea
f57c59ff54 apps: testing: ostest: update licenses to Apache
Gregory Nutt has submitted the SGA
Haltian Ltd has submitted the SGA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2022-03-08 01:44:49 +08:00
Huang Qi
cc156b908e ostest: Introduce basic setjmp/longjmp test
Signed-off-by: Huang Qi <huangqi3@xiaomi.com>
2022-03-01 12:03:31 +08:00
liucheng5
93dbf8abe2 fix: sensor: modify sensortest for PPG
Modify sensortest for new sensor types PPGD and PPGQ instead old type PPG.

Signed-off-by: liucheng5 <liucheng5@xiaomi.com>
2022-01-28 14:08:16 +08:00
chao.an
cb988a8394 testing/ostest: set the default value to TESTING_OSTEST_FPUSIZE
.config:2053:warning: symbol value '' invalid for TESTING_OSTEST_FPUSIZE

Signed-off-by: chao.an <anchao@xiaomi.com>
2022-01-09 18:07:52 +08:00
Fotis Panagiotopoulos
bc5d8034f1 Typo fixes. 2022-01-06 10:30:41 +08:00
Zeng Zhaoxiu
614b73d321 ostest: sighand.c: add sem_wait in signal handler
task is blocked by semphore1, signal handler is blocked by semphore2,
after post semphore2, the task must get -EINTR.

Signed-off-by: Zeng Zhaoxiu <zhaoxiu.zeng@gmail.com>
2022-01-05 21:34:30 +09:00
Jiuzhu Dong
4a14126d76 ostest: fix assert when enable CONFIG_PRIORITY_INHERITANCE
[ 96.555456] [265] ap: up_assert: Assertion failed at file:semaphore/sem_holder.c line: 112 task: pt-0x5b09fd0b
[ 96.555657] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.555828] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.556023] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.556222] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.556437] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.556639] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.556842] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b
[ 96.557036] [265] ap: up_assert: Assertion failed at file:semaphore/sem_recover.c line: 86 task: pt-0x5b09fd0b

Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2022-01-05 20:20:45 +08:00
Petro Karashchenko
5ac15130db apps: remove space befone newline in logs
Signed-off-by: Petro Karashchenko <petro.karashchenko@gmail.com>
2021-12-27 20:52:08 -06:00
Xiang Xiao
87d8494a6e testing/ostest: Include nuttx/arch.h explicitly
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-08 16:32:47 +08:00
Xiang Xiao
14a52b1933 testing/ostest: Don't include arch/tls.h
since it doesn't exist any more

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-12-05 23:06:02 -03:00
Juha Niskanen
0c21a89a3f testing/ostest: remove spurious redefinitions of NULL
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-11-29 11:14:42 -06:00
Xiang Xiao
c9f736005a testing/fstest: Zero g_nfailed too in fstest_delallfiles
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
f8ebeb8fd8 testing/fstest: Print the delta of memory info
to catch the memmory leak quickly

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
121a6e58ff testing/fstest: Remove g_media_full since it isn't really used
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
7c4ddaeede testing/fstest: Don't reuse the deleted name
to simplify the root cause analysis

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
1187351144 testing/fstest: Compare the file name directly
and remove crc of file name

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
3b64ad34c3 testing/fstest: Fix the typo error
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-27 10:07:01 -03:00
Xiang Xiao
75c11d4480 examples/helloxx: add extern "C" to main implementation directly
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-23 17:23:05 -03:00
Xiang Xiao
fd2289a8a2 testing/sensortest: Fix printf format warning
sensortest.c: In function 'print_valu':
Error: sensortest.c:161:10: error: format '%u' expects argument of type 'unsigned int', but argument 4 has type 'uint32_t' {aka 'long unsigned int'} [-Werror=format=]
  161 |   printf("%s: timestamp:%" PRIu64 " value:%u\n",
      |          ^~~~~~~~~~~~~~~~~
  162 |          name, event->timestamp, event->ppg);
      |                                  ~~~~~~~~~~
      |                                       |
      |                                       uint32_t {aka long unsigned int}
sensortest.c:161:44: note: format string is defined here
  161 |   printf("%s: timestamp:%" PRIu64 " value:%u\n",
      |                                           ~^
      |                                            |
      |                                            unsigned int
      |                                           %lu
sensortest.c: In function 'print_gps':
Error: sensortest.c:169:10: error: format '%u' expects argument of type 'unsigned int', but argument 15 has type 'uint32_t' {aka 'long unsigned int'} [-Werror=format=]
  169 |   printf("%s: timestamp:%" PRIu64 " time_utc: %" PRIu64 " latitude: %f "
      |          ^~~~~~~~~~~~~~~~~
......
  175 |          event->ground_speed, event->course, event->satellites_used);
      |                                              ~~~~~~~~~~~~~~~~~~~~~~
      |                                                   |
      |                                                   uint32_t {aka long unsigned int}
sensortest.c:172:13: note: format string is defined here
  172 |          " %u\n", name, event->timestamp, event->time_utc, event->latitude,
      |            ~^
      |             |
      |             unsigned int
      |            %lu
sensortest.c: In function 'print_gps_satellite':
Error: sensortest.c:183:10: error: format '%u' expects argument of type 'unsigned int', but argument 4 has type 'uint32_t' {aka 'long unsigned int'} [-Werror=format=]
  183 |   printf("%s: timestamp: %" PRIu64 " count: %u satellites: %u", name,
      |          ^~~~~~~~~~~~~~~~~~
  184 |          event->timestamp, event->count, event->satellites);
      |                            ~~~~~~~~~~~~
      |                                 |
      |                                 uint32_t {aka long unsigned int}
sensortest.c:183:46: note: format string is defined here
  183 |   printf("%s: timestamp: %" PRIu64 " count: %u satellites: %u", name,
      |                                             ~^
      |                                              |
      |                                              unsigned int
      |                                             %lu
Error: sensortest.c:183:10: error: format '%u' expects argument of type 'unsigned int', but argument 5 has type 'uint32_t' {aka 'long unsigned int'} [-Werror=format=]
  183 |   printf("%s: timestamp: %" PRIu64 " count: %u satellites: %u", name,
      |          ^~~~~~~~~~~~~~~~~~
  184 |          event->timestamp, event->count, event->satellites);
      |                                          ~~~~~~~~~~~~~~~~~
      |                                               |
      |                                               uint32_t {aka long unsigned int}
sensortest.c:183:61: note: format string is defined here
  183 |   printf("%s: timestamp: %" PRIu64 " count: %u satellites: %u", name,
      |                                                            ~^
      |                                                             |
      |                                                             unsigned int
      |                                                            %lu

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-19 00:14:59 +08:00
Xiang Xiao
ea91e25558 testing/sensortest: Fix printf format warning
sensortest.c: In function 'print_gps':
Error: sensortest.c:169:29: error: format '%llu' expects argument of type 'long long unsigned int', but argument 3 has type 'uint64_t' {aka 'long unsigned int'} [-Werror=format=]
  169 |   printf("%s: timestamp: %llu time_utc: %llu latitude: %f longitude: %f "
      |                          ~~~^
      |                             |
      |                             long long unsigned int
      |                          %lu
......
  172 |          " %u\n", name, event->timestamp, event->time_utc, event->latitude,
      |                         ~~~~~~~~~~~~~~~~
      |                              |
      |                              uint64_t {aka long unsigned int}
Error: sensortest.c:169:44: error: format '%llu' expects argument of type 'long long unsigned int', but argument 4 has type 'uint64_t' {aka 'long unsigned int'} [-Werror=format=]
  169 |   printf("%s: timestamp: %llu time_utc: %llu latitude: %f longitude: %f "
      |                                         ~~~^
      |                                            |
      |                                            long long unsigned int
      |                                         %lu
......
  172 |          " %u\n", name, event->timestamp, event->time_utc, event->latitude,
      |                                           ~~~~~~~~~~~~~~~
      |                                                |
      |                                                uint64_t {aka long unsigned int}
sensortest.c: In function 'print_gps_satellite':
Error: sensortest.c:183:29: error: format '%llu' expects argument of type 'long long unsigned int', but argument 3 has type 'uint64_t' {aka 'long unsigned int'} [-Werror=format=]
  183 |   printf("%s: timestamp: %llu count: %u satellites: %u", name,
      |                          ~~~^
      |                             |
      |                             long long unsigned int
      |                          %lu
  184 |          event->timestamp, event->count, event->satellites);
      |          ~~~~~~~~~~~~~~~~
      |               |
      |               uint64_t {aka long unsigned int}

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-11-18 09:57:40 -03:00
丁欣童
0f58795f10 sensortest: support new gps struct and more sensor type.
Signed-off-by: buyuer <dingddding@163.com>
2021-11-17 08:59:43 -06:00
Xiang Xiao
3ba18e5407 testing/ostest: Fix the compiler warning
aio.c: In function ‘check_done’:
aio.c:158:41: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘ssize_t’ {aka ‘volatile long int’} [-Wformat=]
  158 |           printf("  list[%d]. result = %d\n", i, aiocbp->aio_result);
      |                                        ~^        ~~~~~~~~~~~~~~~~~~
      |                                         |              |
      |                                         int            ssize_t {aka volatile long int}
      |                                        %ld
aio.c: In function ‘remove_done’:
aio.c:222:41: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘ssize_t’ {aka ‘volatile long int’} [-Wformat=]
  222 |           printf("  list[%d]. result = %d\n", i, aiocbp->aio_result);
      |                                        ~^        ~~~~~~~~~~~~~~~~~~
      |                                         |              |
      |                                         int            ssize_t {aka volatile long int}
      |                                        %ld

sporadic2.c: In function ‘sporadic2_test’:
sporadic2.c:313:10: warning: format ‘%i’ expects argument of type ‘int’, but argument 4 has type ‘long int’ [-Wformat=]
  313 |   printf("Sporadic 1: prio high %d, low %d, repl %" PRIi32 " ns\n",
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /home/xiaoxiang/backup/os/nuttx/nuttx/include/stdint.h:35,
                 from /home/xiaoxiang/backup/os/nuttx/nuttx/include/sys/types.h:32,
                 from /home/xiaoxiang/backup/os/nuttx/nuttx/include/stdio.h:30,
                 from sporadic2.c:27:
/home/xiaoxiang/backup/os/nuttx/nuttx/include/arch/inttypes.h:51:24: note: format string is defined here
   51 | #  define PRIi32      "i"
sporadic2.c:315:10: warning: format ‘%i’ expects argument of type ‘int’, but argument 4 has type ‘long int’ [-Wformat=]
  315 |   printf("Sporadic 2: prio high %d, low %d, repl %" PRIi32 " ns\n",
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-10-31 14:07:25 -03:00
Jiuzhu Dong
293b89af44 sensortest: modify errno type when api not support
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-09-11 23:02:21 +02:00
Juha Niskanen
4f095a193e testing/smart: fix wrong hard-coded device pathname and sector size
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-08-27 10:56:57 +08:00
Juha Niskanen
b283289986 apps: fix miscellaneous typos
Signed-off-by: Juha Niskanen <juha.niskanen@haltian.com>
2021-08-26 11:39:28 -07:00
anjianjun
54d94d21b8 testing/fstest:Support test fs with parameter
Signed-off-by: anjianjun <anjianjun@xiaomi.com>
2021-07-30 21:02:42 -07:00
Abdelatif Guettouche
b1fb24d5b9 testing/ostest/barrier: Remove duplicate initialization of the barrier's
attributes.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-07-28 21:13:14 -07:00
Abdelatif Guettouche
025ce0e008 testing/ostest/barrier: Fix the message printed when
pthread_barrier_init fails.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-07-28 21:13:14 -07:00
Abdelatif Guettouche
eb228229d8 testing/smp/smp_main.c: Remove duplicate initialization of the barrier's
attributes.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-07-28 21:13:14 -07:00
Abdelatif Guettouche
e5667b1d3d testing/smp/smp_main.c: Fix the message printed when
pthread_barrier_init fails.

Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-07-28 21:13:14 -07:00
songnannan
f4b84c0ba7 fix(sensortest): move set_interval and batch before activate.
modify coding style err.

Change-Id: Ib820b81a9a774070b5c4778d11ecb70f1f7cd846
Signed-off-by: songnannan <songnannan@xiaomi.com>
2021-07-22 13:05:20 +02:00
Jiuzhu Dong
993693d5f4 testing/sensor: fix bug about -h
MIRTOS-334

Change-Id: I1803ad1c769189f42d223111c7eb898e091eeccc
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-06-17 09:21:38 +01:00
Jiuzhu Dong
d838666844 sensortest: add '\n' for gps output debug log
MIRTOS-328

Change-Id: Iae2925beae2d63c3ce212875109c3a25cb941a90
Signed-off-by: Jiuzhu Dong <dongjiuzhu1@xiaomi.com>
2021-06-17 09:21:38 +01:00
Alin Jerpelea
6f4dccdb64 testing: fix relative path CI error
error: Path relative to repository other than nuttx must begin with the root directory
Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-16 09:03:06 -05:00
Xiang Xiao
a91e10f8e4 testing/fstest: Add O_TRUNC flag in fstest_wrfile
MIRTOS-177

to avoid the interference from the lasting run

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-15 09:16:03 -03:00
Xiang Xiao
a7b7c90f6a Fix nxstyle warning
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-06-14 23:00:25 +01:00
paopao
26277cc946 testing: Exit with non zero value in the failure path
Change-Id: I90115ab51bcd937b8443a6aab2fabb6cd559aa85
Signed-off-by: paopao <v-cuixiaoling@xiaomi.com>
2021-06-14 23:00:25 +01:00
Alin Jerpelea
22ff4b686a testing: cxxtest: update licenses to Apache
Gregory Nutt is the copyright holder for those files and he has submitted the
SGA as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-11 05:05:27 -05:00
Alin Jerpelea
0f68fb7075 testing: smp: nxstyle fixes
Fixes for errors reported by nxstyle tool

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-10 08:49:24 -05:00
Alin Jerpelea
d2db78f8bc testing: smart_test: nxstyle fixes
Fixes for errors reported by nxstyle tool

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-10 08:49:24 -05:00
Alin Jerpelea
3378b8ef54 testing: ostest: nxstyle fixes
Fixes for errors reported by nxstyle tool

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-10 08:49:24 -05:00
Alin Jerpelea
590307e957 testing: update licenses to Apache
Gregory Nutt is has submitted the SGA

Mark Schulte has submitted the ICLA

Ken Pettit has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-10 08:49:24 -05:00
Masayuki Ishikawa
068e1877b8 testing: getprime: Fix to wait for all the threads to finish
Summary:
- I noticed that sometimes getprime causes ASSERT in tls_getset.c
- This commit fixes this issue.

Impact:
- None

Testing:
- Tested with spresense:wifi_smp

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2021-06-07 21:32:52 -06:00
Alin Jerpelea
1e88c73107 Makefile: Ken Pettit: update licenses to Apache
Gregory Nutt is has submitted the SGA

Ken Pettit has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-07 21:35:33 -05:00
Alin Jerpelea
ea1ced8ba3 Makefiles: Mateusz Szafoni: update licenses to Apache
Gregory Nutt is has submitted the SGA

Mateusz Szafoni has submitted the ICLA

as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-07 21:35:33 -05:00
Alin Jerpelea
ec339bc49a Makefiles: Gregory Nutt: update licenses to Apache
Gregory Nutt is the copyright holder for those files and he has submitted the
SGA as a result we can migrate the licenses to Apache.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2021-06-07 21:35:33 -05:00
Xiang Xiao
1ee948e0c8 Include assert.h for DEBUGASSERT caller
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-24 12:34:37 +09:00
Xiang Xiao
a6ca97d733 ostest: Include errno.h in timedmutex.c
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2021-05-18 12:42:02 +01:00
Abdelatif Guettouche
739ab94d03 testing/unity: Select the latest version.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-05-05 06:05:33 -07:00
Abdelatif Guettouche
e86faa6966 testing/ostest: Fix nxstyle errors.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-04-30 09:17:14 -03:00
Abdelatif Guettouche
0e9f08e454 testing/ostest: Report "ERROR" the same way for all the test cases.
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-04-30 09:17:14 -03:00
Brennan Ashton
e73d71c787 ltp: Resolve compile warnings 2021-04-11 03:43:51 -05:00
Gregory Nutt
dd7c3bfa53 apps/testing/ostest: Add test for required argument format
The Linux man page requires that the getopt_long() and getopt_long_only() functions accept arguments to options in a form like:

    --option=argument

This PR adds a test that missing functionality that was recently added to NuttX.

This change also fixes an error in string comparison that was working before only because of the way that strings are stored by in linker ELF.  The address of the strings were being compared, not the value of the string.

This change effects only the getopt() tests of the OS test.

Tested on a simulator NSH configuration and used to verify the NuttX change.
2021-04-04 14:14:21 -05:00
Gregory Nutt
6a679043e6 testing/ostest: More improvements to getopt() testing/ostest
Fix optind range checking.  optind may index through argc (to the NULL argv entry) on the last option since optind is required to always point to the next command line argument.

Add two more test cases were the final thing on the command line is an invalid long option.

Fix a check that used an older, obsoleted hard-coded value that was not updated.

This should have no impact other than to the getopt() test cases of the OS test.

Tested on the simulator using a modified NSH configuration.
2021-04-04 11:45:24 -05:00
Gregory Nutt
02ef45980b OS Test: Minor improvement to the getopt() test
Add logic to assure that the getopt() functions parse exactly the correct number of parameters.  Previously if the test terminated early, the error would be undetected.  Also, prevents indexing past the end of the results array.

Fixes a coding error that was not causing a test failure.

Add some minimal level of testing for invalid options (this found a good bug in getopt_long()).

Affects only the getopt() test cases of the OS test.

Verified using an NSH simulator configuration set up to add apps/testing/ostest as a built-in command.
2021-04-04 07:15:35 -05:00
Gregory Nutt
99138f6b39 testing/ostest: Add a test of the getopt() family of interfaces.
This new test was used to verify the new implementations of getopt_long() and getopt_long_only() and to verify that there are no regressions to the existing getopts().

Only the OS test is affect by this change.

Verified with the getopt() modifications on a modified version of the sim:nsh configuration.
2021-04-03 01:07:34 -05:00
Dong Heng
d3c7508372 testing/fstest: Add hash checking of file's name to avoid creating same-name file 2021-03-30 00:59:16 -05:00
Alan Carvalho de Assis
f3828ccbca fstest: Force the minimum filename to 4 to avoid collisions 2021-03-25 19:45:48 -07:00
Alan C. Assis
640fd2e860 fstest: Fix printf format error 2021-03-24 23:21:23 +01:00
Gregory Nutt
9f65362dd4 OS test: Improve reporting from the dual thread sporadic test
Results were difficult to interpret because the counts during the high priority, budget interval were included with other counts during the low priority interval.  This corrects that reporting by using two counts:  One for the low and one for the high priority interval.  This makes the results much easier to interpret.

There should be no impact to anything other that the sporadic scheduler case of the OS test.

Tested using the the stm32f4discovery:sporadic configration.  That configuration has no yet been merged but is available from incubator-apps PR 3097.
2021-03-19 23:11:35 -07:00
Gregory Nutt
1d3dda49a8 Extend Testing of Sporadic Schedule in OS test
This commit adds the test developed by Jan Staschulat with Issue #incubator_nuttx/2935

It is expected to cause the OS test to fail for the time being since that issue reports a bug.

Tested using the (new) stm32f4discovery:sporadic configuratioin.
2021-03-18 19:57:58 -07:00