From: Hiroki Shirokura Date: Thu, 13 Feb 2020 23:41:17 +0000 (+0000) Subject: tests: refactor Prefix-SID binary syntax X-Git-Tag: base_7.4~215^2 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=39416574fe874607d8b5cc43cb918a61cb4a831e;p=matthieu%2Ffrr.git tests: refactor Prefix-SID binary syntax Signed-off-by: Hiroki Shirokura --- diff --git a/tests/bgpd/test_mp_attr.c b/tests/bgpd/test_mp_attr.c index d46dd8864e..7fabaad7fa 100644 --- a/tests/bgpd/test_mp_attr.c +++ b/tests/bgpd/test_mp_attr.c @@ -951,12 +951,19 @@ static struct test_segment mp_prefix_sid[] = { "PREFIX-SID", "PREFIX-SID Test 1", { - 0x01, 0x00, 0x07, - 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x02, - 0x03, 0x00, 0x08, 0x00, - 0x00, 0x0a, 0x1b, 0xfe, - 0x00, 0x00, 0x0a + /* TLV[0] Latel-Index TLV */ + 0x01, /* Type 0x01:Label-Index */ + 0x00, 0x07, /* Length */ + 0x00, /* RESERVED */ + 0x00, 0x00, /* Flags */ + 0x00, 0x00, 0x00, 0x02, /* Label Index */ + + /* TLV[1] SRGB TLV */ + 0x03, /* Type 0x03:SRGB */ + 0x00, 0x08, /* Length */ + 0x00, 0x00, /* Flags */ + 0x0a, 0x1b, 0xfe, /* SRGB[0] first label */ + 0x00, 0x00, 0x0a /* SRBG[0] nb-labels in range */ }, .len = 21, .parses = SHOULD_PARSE,