1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551 |
- <?xml version="1.0" encoding="UTF-8"?>
- <SPC5-Config version="1.0.0">
- <application name="NASA OSAL Test Suite" version="1.0.0" standalone="true" locked="false">
- <description>Test specification for the NASA OSAL ChibiOS extension.</description>
- <component id="org.chibios.spc5.components.portable.generic_startup">
- <component id="org.chibios.spc5.components.portable.chibios_unitary_tests_engine" />
- </component>
- <instances>
- <instance locked="false" id="org.chibios.spc5.components.portable.generic_startup" />
- <instance locked="false" id="org.chibios.spc5.components.portable.chibios_unitary_tests_engine">
- <description>
- <brief>
- <value>NASA OSAL Test Suite.</value>
- </brief>
- <copyright>
- <value><![CDATA[/* Copyright statement.*/]]></value>
- </copyright>
- <introduction>
- <value>Test suite for NASA OSAL implementation over ChibiOS/RT. The purpose of this suite is to perform unit tests on the OSAL module and to converge to 100% code coverage through successive improvements.</value>
- </introduction>
- </description>
- <global_data_and_code>
- <code_prefix>
- <value>nasa_osal_</value>
- </code_prefix>
- <global_definitions>
- <value><![CDATA[#define TEST_SUITE_NAME "NASA OSAL over ChibiOS/RT Test Suite"
- #define TASKS_BASE_PRIORITY 200
- #define TASKS_STACK_SIZE 256
- extern THD_WORKING_AREA(wa_test1, TASKS_STACK_SIZE);
- extern THD_WORKING_AREA(wa_test2, TASKS_STACK_SIZE);
- extern THD_WORKING_AREA(wa_test3, TASKS_STACK_SIZE);
- extern THD_WORKING_AREA(wa_test4, TASKS_STACK_SIZE);]]></value>
- </global_definitions>
- <global_code>
- <value><![CDATA[THD_WORKING_AREA(wa_test1, TASKS_STACK_SIZE);
- THD_WORKING_AREA(wa_test2, TASKS_STACK_SIZE);
- THD_WORKING_AREA(wa_test3, TASKS_STACK_SIZE);
- THD_WORKING_AREA(wa_test4, TASKS_STACK_SIZE);]]></value>
- </global_code>
- </global_data_and_code>
- <sequences>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Tasks Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to threading.</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include "osapi.h"
- static void test_task1(void) {
- test_emit_token('A');
- }
- static void test_task2(void) {
- test_emit_token('B');
- }
- static void test_task3(void) {
- test_emit_token('C');
- }
- static void test_task4(void) {
- test_emit_token('D');
- }
- static void delete_handler(void) {
- test_emit_token('C');
- }
- static void test_task_delete(void) {
- test_emit_token('A');
- (void) OS_TaskInstallDeleteHandler(delete_handler);
- while (!OS_TaskDeleteCheck()) {
- (void) OS_TaskDelay(1);
- }
- test_emit_token('B');
- }]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_TaskCreate() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_TaskCreate() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with task_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TaskCreate(NULL, /* Error.*/
- "failing task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with task_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- NULL, /* Error.*/
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with stack_pointer set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- "failing task",
- test_task1,
- (uint32 *)NULL, /* Error.*/
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- "this is a very very long task name", /* Error.*/
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with priority below and above allowed range, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- "failing task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- 0, /* Error.*/
- 0);
- test_assert(err == OS_ERR_INVALID_PRIORITY, "priority error not detected");
- test_assert_sequence("", "task executed");
- err = OS_TaskCreate(&tid,
- "failing task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- 256, /* Error.*/
- 0);
- test_assert(err == OS_ERR_INVALID_PRIORITY, "priority error not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked with a stack size below minimum, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- "failing task",
- test_task1,
- (uint32 *)wa_test1,
- 16, /* Error.*/
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_INVALID_INT_NUM, "stack insufficient size not detected");
- test_assert_sequence("", "task executed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TaskCreate() is invoked twice with duplicated name and then duplicated stack, an error is expected in both cases.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid;
- err = OS_TaskCreate(&tid,
- "running task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_SUCCESS, "task creation failed");
- err = OS_TaskCreate(&tid,
- "running task",
- test_task2,
- (uint32 *)wa_test2,
- sizeof wa_test2,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- err = OS_TaskCreate(&tid,
- "conflicting task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_ERR_NO_FREE_IDS, "stack conflict not detected");
- err = OS_TaskWait(tid);
- test_assert(err == OS_SUCCESS, "wait failed");
- test_assert_sequence("A", "task not executed");
- err = OS_TaskCreate(&tid,
- "running task",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_SUCCESS, "task creation failed");
- err = OS_TaskWait(tid);
- test_assert(err == OS_SUCCESS, "wait failed");
- test_assert_sequence("A", "task not executed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TaskCreate() priority ordering</value>
- </brief>
- <description>
- <value>Four tasks are created at different priorities and in different order. The execution order must happen in order of priority regardless the creation order.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Four tasks are created in priority order from low to high.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid1, tid2, tid3, tid4;
- err = OS_TaskCreate(&tid4,
- "running task 4",
- test_task4,
- (uint32 *)wa_test4,
- sizeof wa_test4,
- TASKS_BASE_PRIORITY - 0,
- 0);
- test_assert(err == OS_SUCCESS, "task 4 creation failed");
- err = OS_TaskCreate(&tid3,
- "running task 3",
- test_task3,
- (uint32 *)wa_test3,
- sizeof wa_test3,
- TASKS_BASE_PRIORITY - 1,
- 0);
- test_assert(err == OS_SUCCESS, "task 3 creation failed");
- err = OS_TaskCreate(&tid2,
- "running task 2",
- test_task2,
- (uint32 *)wa_test2,
- sizeof wa_test2,
- TASKS_BASE_PRIORITY - 2,
- 0);
- test_assert(err == OS_SUCCESS, "task 2 creation failed");
- err = OS_TaskCreate(&tid1,
- "running task 1",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY - 3,
- 0);
- test_assert(err == OS_SUCCESS, "task 1 creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Tasks are made runnable atomically and their execution order tested.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[OS_TaskDelay(5);
- test_assert_sequence("ABCD", "task order violation");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Four tasks are created in priority order from high to low.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid1, tid2, tid3, tid4;
- err = OS_TaskCreate(&tid1,
- "running task 1",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY - 3,
- 0);
- test_assert(err == OS_SUCCESS, "task 1 creation failed");
- err = OS_TaskCreate(&tid2,
- "running task 2",
- test_task2,
- (uint32 *)wa_test2,
- sizeof wa_test2,
- TASKS_BASE_PRIORITY - 2,
- 0);
- test_assert(err == OS_SUCCESS, "task 2 creation failed");
- err = OS_TaskCreate(&tid3,
- "running task 3",
- test_task3,
- (uint32 *)wa_test3,
- sizeof wa_test3,
- TASKS_BASE_PRIORITY - 1,
- 0);
- test_assert(err == OS_SUCCESS, "task 3 creation failed");
- err = OS_TaskCreate(&tid4,
- "running task 4",
- test_task4,
- (uint32 *)wa_test4,
- sizeof wa_test4,
- TASKS_BASE_PRIORITY - 0,
- 0);
- test_assert(err == OS_SUCCESS, "task 4 creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Tasks are made runnable atomically and their execution order tested.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[OS_TaskDelay(5);
- test_assert_sequence("ABCD", "task order violation");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Four tasks are created in an not ordered way.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tid1, tid2, tid3, tid4;
- err = OS_TaskCreate(&tid2,
- "running task 2",
- test_task2,
- (uint32 *)wa_test2,
- sizeof wa_test2,
- TASKS_BASE_PRIORITY - 2,
- 0);
- test_assert(err == OS_SUCCESS, "task 2 creation failed");
- err = OS_TaskCreate(&tid1,
- "running task 1",
- test_task1,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY - 3,
- 0);
- test_assert(err == OS_SUCCESS, "task 1 creation failed");
- err = OS_TaskCreate(&tid4,
- "running task 4",
- test_task4,
- (uint32 *)wa_test4,
- sizeof wa_test4,
- TASKS_BASE_PRIORITY - 0,
- 0);
- test_assert(err == OS_SUCCESS, "task 4 creation failed");
- err = OS_TaskCreate(&tid3,
- "running task 3",
- test_task3,
- (uint32 *)wa_test3,
- sizeof wa_test3,
- TASKS_BASE_PRIORITY - 1,
- 0);
- test_assert(err == OS_SUCCESS, "task 3 creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Tasks are made runnable atomically and their execution order tested.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[OS_TaskDelay(5);
- test_assert_sequence("ABCD", "task order violation");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TaskDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_TaskDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_TaskDelete() is invoked with task_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TaskDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong task id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TaskDelete() and OS_TaskInstallDeleteHandler() functionality</value>
- </brief>
- <description>
- <value>OS_TaskDelete() and OS_TaskInstallDeleteHandler() are tested for functionality.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value><![CDATA[uint32 tid;]]></value>
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Creating a task executing an infinite loop.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TaskCreate(&tid,
- "deletable task",
- test_task_delete,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_SUCCESS, "deletable task creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Letting the task run for a while then deleting it. A check is performed on the correct execution of the delete handler.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- (void) OS_TaskDelay(50);
- err = OS_TaskDelete(tid);
- test_assert(err == OS_SUCCESS, "delete failed");
- test_assert_sequence("ABC", "events order violation");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Queues Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to queues</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include <string.h>
- #include "osapi.h"
- uint32 qid, tid;
- #define WRITER_NUM_MESSAGES 16
- #define MESSAGE_SIZE 20
- static void test_task_writer(void) {
- unsigned i;
- int32 err;
- for (i = 0; i < WRITER_NUM_MESSAGES; i++) {
- err = OS_QueuePut(qid, "Hello World", 12, 0);
- if (err != OS_SUCCESS) {
- test_emit_token('*');
- }
- }
- }]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_QueueCreate() and OS_QueueDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_QueueCreate() and OS_QueueDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_QueueCreate() is invoked with queue_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueCreate(NULL, /* Error.*/
- "failing queue",
- 4,
- 128,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueCreate() is invoked with task_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 qid;
- err = OS_QueueCreate(&qid,
- NULL, /* Error.*/
- 4,
- 128,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueCreate() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 qid;
- err = OS_QueueCreate(&qid,
- "very very long queue name", /* Error.*/
- 4,
- 128,
- 0);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueDelete() is invoked with queue_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong queue id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueCreate() is invoked twice with duplicated name, an error is expected, then the queue is deleted using OS_QueueDelete().</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 qid1, qid2;
- err = OS_QueueCreate(&qid1, "my queue", 4, 128, 0);
- test_assert(err == OS_SUCCESS, "queue creation failed");
- err = OS_QueueCreate(&qid2, "my queue", 4, 128, 0);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- err = OS_QueueDelete(qid1);
- test_assert(err == OS_SUCCESS, "queue deletion failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_QueueGetIdByName() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_QueueGetIdByName() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_QueueGetIdByName() is invoked with queue_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGetIdByName(NULL, "queue");
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueGetIdByName() is invoked with queue_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGetIdByName(&qid, NULL);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_QueueGetIdByName() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGetIdByName(&qid, "very very long queue name");
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_QueuePut() and OS_QueueGet() functionality</value>
- </brief>
- <description>
- <value>A task writes on a queue, the messages are retrieved on the other side in blocking mode.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[qid = 0;
- tid = 0;]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (qid != 0) {
- (void) OS_QueueDelete(qid);
- }
- if (tid != 0) {
- (void) OS_TaskWait(tid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value><![CDATA[uint32 tid;
- unsigned i;]]></value>
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Creataing a queue with depth 4 and message size 20</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueCreate(&qid, "test queue", 4, MESSAGE_SIZE, 0);
- test_assert(err == OS_SUCCESS, "queue creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Creating the writer task.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TaskCreate(&tid,
- "writer task",
- test_task_writer,
- (uint32 *)wa_test1,
- sizeof wa_test1,
- TASKS_BASE_PRIORITY,
- 0);
- test_assert(err == OS_SUCCESS, "writer task creation failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Reading messages from the writer task.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[for (i = 0; i < WRITER_NUM_MESSAGES; i++) {
- int32 err;
- char data[MESSAGE_SIZE];
- uint32 copied;
- err = OS_QueueGet(qid, data, MESSAGE_SIZE, &copied, OS_Milli2Ticks(200));
- test_assert(err == OS_SUCCESS, "timed out");
- test_assert(strncmp(data, "Hello World", sizeof (data)) == 0,
- "wrong message");
- }]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Waiting for task termination then checking for errors.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[(void) OS_TaskWait(tid);
- tid = 0;
- test_assert_sequence("", "queue write errors occurred");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_QueueGet() with timeout functionality</value>
- </brief>
- <description>
- <value>OS_QueueGet() timeout functionality is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[qid = 0;
- (void) OS_QueueCreate(&qid, "test queue", 2, MESSAGE_SIZE, 0);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (qid != 0) {
- OS_QueueDelete(qid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value><![CDATA[uint32 local_qid;
- uint32 copied;
- char data[MESSAGE_SIZE];]]></value>
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Retrieving the queue by name.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGetIdByName(&local_qid, "test queue");
- test_assert(err == OS_SUCCESS, "queue not found");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Get operation with a one second timeout, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGet(qid, data, MESSAGE_SIZE, &copied, OS_Milli2Ticks(1000));
- test_assert(err == OS_QUEUE_TIMEOUT, "unexpected error code");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Get operation in non-blocking mode, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_QueueGet(qid, data, MESSAGE_SIZE, &copied, OS_CHECK);
- test_assert(err == OS_QUEUE_EMPTY, "unexpected error code");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Timers Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to timers</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include <string.h>
- #include "osapi.h"
- uint32 tmid;
- uint32 cnt;
- static void tmr_callback(uint32 timer_id) {
- (void)timer_id;
- cnt++;
- }]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_TimerCreate() and OS_TimerDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_TimerCreate() and OS_TimerDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked with timer_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 accuracy;
- err = OS_TimerCreate(NULL, /* Error.*/
- "failing timer",
- &accuracy,
- tmr_callback);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked with timer_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tmid;
- uint32 accuracy;
- err = OS_TimerCreate(&tmid,
- NULL, /* Error.*/
- &accuracy,
- tmr_callback);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked with accuracy set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tmid;
- err = OS_TimerCreate(&tmid,
- "failing timer",
- NULL, /* Error.*/
- tmr_callback);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked with callback_ptr set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tmid;
- uint32 accuracy;
- err = OS_TimerCreate(&tmid,
- "failing timer",
- &accuracy,
- NULL); /* Error.*/
- test_assert(err == OS_TIMER_ERR_INVALID_ARGS, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked with a very long timer name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tmid;
- uint32 accuracy;
- err = OS_TimerCreate(&tmid,
- "very very long timer name", /* Error.*/
- &accuracy,
- tmr_callback);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerDelete() is invoked with timer_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong timer id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerCreate() is invoked twice with duplicated name, an error is expected, then the queue is deleted using OS_TimerDelete().</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 tmid1, tmid2;
- uint32 accuracy;
- err = OS_TimerCreate(&tmid1, "my timer", &accuracy, tmr_callback);
- test_assert(err == OS_SUCCESS, "timer creation failed");
- err = OS_TimerCreate(&tmid2, "my timer", &accuracy, tmr_callback);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- err = OS_TimerDelete(tmid1);
- test_assert(err == OS_SUCCESS, "timer deletion failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TimerSet() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_TimerSet() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_TimerSet() is invoked with timer_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerSet((uint32)-1, 10, 10);
- test_assert(err == OS_ERR_INVALID_ID, "invalid timer_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TimerGetIdByName() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_TimerGetIdByName() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_TimerGetIdByName() is invoked with timer_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerGetIdByName(NULL, "timer");
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerGetIdByName() is invoked with timer name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerGetIdByName(&tmid, NULL);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_TimerGetIdByName() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerGetIdByName(&tmid, "very very long timer name");
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TimerSet() one-shot functionality</value>
- </brief>
- <description>
- <value>A timer is tested in one-shot mode.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[uint32 accuracy;
- cnt = 0;
- tmid = 0;
- (void) OS_TimerCreate(&tmid, "test timer", &accuracy, tmr_callback);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (tmid != 0) {
- (void) OS_TimerDelete(tmid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value><![CDATA[uint32 local_tmid;]]></value>
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Retrieving the timer by name.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerGetIdByName(&local_tmid, "test timer");
- test_assert(err == OS_SUCCESS, "timer not found");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Setting up the timer for a 70mS one-shot tick.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[uint32 err;
- err = OS_TimerSet(local_tmid, 70000, 0);
- test_assert(err == OS_SUCCESS, "timer setup failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Waiting one second then counting the occurred ticks.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[(void) OS_TaskDelay(1000);
- test_assert(cnt == 1, "wrong ticks");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_TimerSet() periodic functionality</value>
- </brief>
- <description>
- <value>A timer is tested in periodic mode.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[uint32 accuracy;
- cnt = 0;
- tmid = 0;
- (void) OS_TimerCreate(&tmid, "test timer", &accuracy, tmr_callback);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (tmid != 0) {
- (void) OS_TimerSet(tmid, 0, 0);
- (void) OS_TimerDelete(tmid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value><![CDATA[uint32 local_tmid;]]></value>
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>Retrieving the timer by name.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_TimerGetIdByName(&local_tmid, "test timer");
- test_assert(err == OS_SUCCESS, "timer not found");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Setting up the timer for a 70mS periodic tick.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[uint32 err;
- err = OS_TimerSet(local_tmid, 70000, 70000);
- test_assert(err == OS_SUCCESS, "timer setup failed");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Waiting one second then counting the occurred ticks.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[(void) OS_TaskDelay(1000);
- test_assert(cnt == 14, "wrong ticks");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>Stopping the timer.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[uint32 err;
- err = OS_TimerSet(local_tmid, 0, 0);
- test_assert(err == OS_SUCCESS, "timer stop failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Binary Semaphores Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to binary semaphores.</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include "osapi.h"
- uint32 bsid;]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_BinSemCreate() and OS_BinSemDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemCreate() and OS_BinSemDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemCreate() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemCreate(NULL, /* Error.*/
- "failing semaphore",
- 0,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemCreate() is invoked with sem_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemCreate(&bsid,
- NULL, /* Error.*/
- 0,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemCreate() is invoked with an invalid sem_initial_value, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemCreate(&bsid,
- "failing semaphore",
- 2, /* Error.*/
- 0);
- test_assert(err == OS_INVALID_INT_NUM, "counter error not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemCreate() is invoked with a very long timer name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[#if 0 /* Semaphore name currently not implemented.*/
- int32 err;
- err = OS_BinSemCreate(&bsid,
- "very very long semaphore name", /* Error.*/
- 0,
- 0);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");
- #endif]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemDelete() is invoked with timer_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong semaphore id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemCreate() is invoked twice with duplicated name, an error is expected, then the queue is deleted using OS_BinSemDelete().</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 bsid1; /*, bsid2;*/
- err = OS_BinSemCreate(&bsid1, "my semaphore", 0, 0);
- test_assert(err == OS_SUCCESS, "semaphore creation failed");
- #if 0 /* Semaphore name currently not implemented.*/
- err = OS_BinSemCreate(&bsid2, "my semaphore", 0, 0);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- #endif
- err = OS_BinSemDelete(bsid1);
- test_assert(err == OS_SUCCESS, "semaphore deletion failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemFlush() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemFlush() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemFlush() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemFlush((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemGive() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemGive() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemGive() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemGive((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemTake() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemTake() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemTake() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemTake((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemTimedWait() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemTimedWait() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[bsid = 0;
- (void) OS_BinSemCreate(&bsid, "test semaphore", 0, 0);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (bsid > 0) {
- (void) OS_BinSemDelete(bsid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemTimedWait() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemTimedWait((uint32)-1, 1000);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemTimedWait() is invoked with msecs set to 0, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemTimedWait(bsid, 0);
- test_assert(err == OS_INVALID_INT_NUM, "invalid msec not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemGetIdByName() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_BinSemGetIdByName() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemGetIdByName() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemGetIdByName(NULL, "semaphore");
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemGetIdByName() is invoked with semaphore name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemGetIdByName(&bsid, NULL);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_BinSemGetIdByName() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemGetIdByName(&bsid, "very very long semaphore name");
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_BinSemTimedWait() timeout functionality</value>
- </brief>
- <description>
- <value>OS_BinSemCreate() timeout functionality is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[bsid = 0;
- (void) OS_BinSemCreate(&bsid, "test semaphore", 0, 0);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (bsid > 0) {
- (void) OS_BinSemDelete(bsid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_BinSemTimedWait() is invoked with timeout set to one second, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_BinSemTimedWait(bsid, 1000);
- test_assert(err == OS_SEM_TIMEOUT, "unexpected error code");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Counter Semaphores Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to counter semaphores.</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include "osapi.h"
- uint32 csid;]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_CountSemCreate() and OS_CountSemDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_CountSemCreate() and OS_CountSemDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemCreate() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemCreate(NULL, /* Error.*/
- "failing semaphore",
- 0,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemCreate() is invoked with sem_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemCreate(&csid,
- NULL, /* Error.*/
- 0,
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemCreate() is invoked with an invalid sem_initial_value, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemCreate(&csid,
- "failing semaphore",
- (uint32)-1, /* Error.*/
- 0);
- test_assert(err == OS_INVALID_INT_NUM, "counter error not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemCreate() is invoked with a very long timer name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[#if 0 /* Semaphore name currently not implemented.*/
- int32 err;
- err = OS_CountSemCreate(&csid,
- "very very long semaphore name",/* Error.*/
- 0,
- 0);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");
- #endif]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemDelete() is invoked with timer_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong semaphore id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemCreate() is invoked twice with duplicated name, an error is expected, then the queue is deleted using OS_CountSemDelete().</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 csid1; /*, csid2;*/
- err = OS_CountSemCreate(&csid1, "my semaphore", 0, 0);
- test_assert(err == OS_SUCCESS, "semaphore creation failed");
- #if 0 /* Semaphore name currently not implemented.*/
- err = OS_CountSemCreate(&csid2, "my semaphore", 0, 0);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- #endif
- err = OS_CountSemDelete(csid1);
- test_assert(err == OS_SUCCESS, "semaphore deletion failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_CountSemGive() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_CountSemGive() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemGive() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemGive((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_CountSemTake() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_CountSemTake() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemTake() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemTake((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_CountSemTimedWait() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_CountSemTimedWait() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[csid = 0;
- (void) OS_CountSemCreate(&csid, "test semaphore", 0, 0);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (csid > 0) {
- (void) OS_CountSemDelete(csid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemTimedWait() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemTimedWait((uint32)-1, 1000);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemTimedWait() is invoked with msecs set to 0, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemTimedWait(csid, 0);
- test_assert(err == OS_INVALID_INT_NUM, "invalid msec not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_CountSemGetIdByName() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_CountSemGetIdByName() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemGetIdByName() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemGetIdByName(NULL, "semaphore");
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemGetIdByName() is invoked with semaphore name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemGetIdByName(&csid, NULL);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_CountSemGetIdByName() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemGetIdByName(&csid, "very very long semaphore name");
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_CountSemTimedWait() timeout functionality</value>
- </brief>
- <description>
- <value>OS_CountSemCreate() timeout functionality is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value><![CDATA[csid = 0;
- (void) OS_CountSemCreate(&csid, "test semaphore", 0, 0);]]></value>
- </setup_code>
- <teardown_code>
- <value><![CDATA[if (csid > 0) {
- (void) OS_CountSemDelete(csid);
- }]]></value>
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_CountSemTimedWait() is invoked with timeout set to one second, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_CountSemTimedWait(csid, 1000);
- test_assert(err == OS_SEM_TIMEOUT, "unexpected error code");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- <sequence>
- <type index="0">
- <value>Internal Tests</value>
- </type>
- <brief>
- <value>Mutex Semaphores Functionality</value>
- </brief>
- <description>
- <value>This sequence tests the NASA OSAL over ChibiOS/RT functionalities related to mutex semaphores.</value>
- </description>
- <condition>
- <value />
- </condition>
- <shared_code>
- <value><![CDATA[#include "osapi.h"
- uint32 msid;]]></value>
- </shared_code>
- <cases>
- <case>
- <brief>
- <value>OS_MutSemCreate() and OS_MutSemDelete() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_MutSemCreate() and OS_MutSemDelete() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_MutSemCreate() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemCreate(NULL, /* Error.*/
- "failing semaphore",
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemCreate() is invoked with sem_name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemCreate(&msid,
- NULL, /* Error.*/
- 0);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemCreate() is invoked with a very long timer name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[#if 0 /* Semaphore name currently not implemented.*/
- int32 err;
- err = OS_MutSemCreate(&msid,
- "very very long semaphore name", /* Error.*/
- 0);
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");
- #endif]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemDelete() is invoked with timer_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemDelete((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "wrong semaphore id not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemCreate() is invoked twice with duplicated name, an error is expected, then the queue is deleted using OS_MutSemDelete().</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- uint32 msid1; /*, msid2;*/
- err = OS_MutSemCreate(&msid1, "my semaphore", 0);
- test_assert(err == OS_SUCCESS, "semaphore creation failed");
- #if 0 /* Semaphore name currently not implemented.*/
- err = OS_MutSemCreate(&msid2, "my semaphore", 0);
- test_assert(err == OS_ERR_NAME_TAKEN, "name conflict not detected");
- #endif
- err = OS_MutSemDelete(msid1);
- test_assert(err == OS_SUCCESS, "semaphore deletion failed");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_MutSemGive() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_MutSemGive() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_MutSemGive() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemGive((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_MutSemTake() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_MutSemTake() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_MutSemTake() is invoked with sem_id set to -1, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemTake((uint32)-1);
- test_assert(err == OS_ERR_INVALID_ID, "invalid sem_id not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- <case>
- <brief>
- <value>OS_MutSemGetIdByName() errors</value>
- </brief>
- <description>
- <value>Parameters checking in OS_MutSemGetIdByName() is tested.</value>
- </description>
- <condition>
- <value />
- </condition>
- <various_code>
- <setup_code>
- <value />
- </setup_code>
- <teardown_code>
- <value />
- </teardown_code>
- <local_variables>
- <value />
- </local_variables>
- </various_code>
- <steps>
- <step>
- <description>
- <value>OS_MutSemGetIdByName() is invoked with sem_id set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemGetIdByName(NULL, "semaphore");
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemGetIdByName() is invoked with semaphore name set to NULL, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemGetIdByName(&msid, NULL);
- test_assert(err == OS_INVALID_POINTER, "NULL not detected");]]></value>
- </code>
- </step>
- <step>
- <description>
- <value>OS_MutSemGetIdByName() is invoked with a very long task name, an error is expected.</value>
- </description>
- <tags>
- <value />
- </tags>
- <code>
- <value><![CDATA[int32 err;
- err = OS_MutSemGetIdByName(&msid, "very very long semaphore name");
- test_assert(err == OS_ERR_NAME_TOO_LONG, "name limit not detected");]]></value>
- </code>
- </step>
- </steps>
- </case>
- </cases>
- </sequence>
- </sequences>
- </instance>
- </instances>
- <exportedFeatures />
- </application>
- </SPC5-Config>
|