Message ID | 20210720194301.23243-1-justin.iurman@uliege.be |
---|---|
Headers | show |
Series | Support for the IOAM Pre-allocated Trace with IPv6 | expand |
On 7/20/21 1:43 PM, Justin Iurman wrote: > +run() > +{ > + echo -n "IOAM test... " > + > + ip netns exec ioam-node-alpha ping6 -c 5 -W 1 db02::2 &>/dev/null > + if [ $? != 0 ]; then > + echo "FAILED" > + cleanup &>/dev/null > + exit 0 > + fi > + > + ip netns exec ioam-node-gamma ./ioam6_parser veth0 2 ${IOAM_NAMESPACE} ${IOAM_TRACE_TYPE} 64 ${ALPHA[0]} ${ALPHA[1]} ${ALPHA[2]} ${ALPHA[3]} ${ALPHA[4]} ${ALPHA[5]} ${ALPHA[6]} ${ALPHA[7]} ${ALPHA[8]} "${ALPHA[9]}" 63 ${BETA[0]} ${BETA[1]} ${BETA[2]} ${BETA[3]} ${BETA[4]} ${BETA[5]} ${BETA[6]} ${BETA[7]} ${BETA[8]} & > + > + local spid=$! > + sleep 0.1 > + > + ip netns exec ioam-node-alpha ping6 -c 5 -W 1 db02::2 &>/dev/null > + > + wait $spid > + [ $? = 0 ] && echo "PASSED" || echo "FAILED" > +} > + > +cleanup &>/dev/null > +setup > +run > +cleanup &>/dev/null Can you add negative tests as well? i.e, things work like they should when enabled and configured properly, fail when the test should not and include any invalid combinations of parameters.
>> +run() >> +{ >> + echo -n "IOAM test... " >> + >> + ip netns exec ioam-node-alpha ping6 -c 5 -W 1 db02::2 &>/dev/null >> + if [ $? != 0 ]; then >> + echo "FAILED" >> + cleanup &>/dev/null >> + exit 0 >> + fi >> + >> + ip netns exec ioam-node-gamma ./ioam6_parser veth0 2 ${IOAM_NAMESPACE} >> ${IOAM_TRACE_TYPE} 64 ${ALPHA[0]} ${ALPHA[1]} ${ALPHA[2]} ${ALPHA[3]} >> ${ALPHA[4]} ${ALPHA[5]} ${ALPHA[6]} ${ALPHA[7]} ${ALPHA[8]} "${ALPHA[9]}" 63 >> ${BETA[0]} ${BETA[1]} ${BETA[2]} ${BETA[3]} ${BETA[4]} ${BETA[5]} ${BETA[6]} >> ${BETA[7]} ${BETA[8]} & >> + >> + local spid=$! >> + sleep 0.1 >> + >> + ip netns exec ioam-node-alpha ping6 -c 5 -W 1 db02::2 &>/dev/null >> + >> + wait $spid >> + [ $? = 0 ] && echo "PASSED" || echo "FAILED" >> +} >> + >> +cleanup &>/dev/null >> +setup >> +run >> +cleanup &>/dev/null > > Can you add negative tests as well? i.e, things work like they should > when enabled and configured properly, fail when the test should not and > include any invalid combinations of parameters. Hmmm... I think I got your point but not sure on details you have in mind. Maybe should we take a table during the netdev conf and discuss it live.