diff --git a/tests/aspath_test.c b/tests/aspath_test.c
index 9170455..7fdb5e2 100644
--- a/tests/aspath_test.c
+++ b/tests/aspath_test.c
@@ -443,6 +443,7 @@
   const int cap;	/* capabilities to set for peer */
   const char attrheader [1024];
   size_t len;
+  const struct test_segment *old_segment;
 } aspath_tests [] =
 {
   /* 0 */
@@ -590,10 +591,10 @@
   },
   /* 11 */
   {
-    "4b AS_PATH: confed",
+    "4b AS4_PATH w/o AS_PATH",
     &test_segments[6],
-    "8466 3 52737 4096",
-    AS4_DATA, -1,
+    NULL,
+    AS4_DATA, 0,
     PEER_CAP_AS4_ADV,
     { BGP_ATTR_FLAG_TRANS|BGP_ATTR_FLAG_OPTIONAL,
       BGP_ATTR_AS4_PATH, 
@@ -601,6 +602,20 @@
     },
     3,
   },
+  /* 12 */
+  {
+    "4b AS4_PATH: confed",
+    &test_segments[6],
+    "8466 3 52737 4096 (123 456 789)",
+    AS4_DATA, 0,
+    PEER_CAP_AS4_ADV,
+    { BGP_ATTR_FLAG_TRANS|BGP_ATTR_FLAG_OPTIONAL,
+      BGP_ATTR_AS4_PATH, 
+      14,
+    },
+    3,
+    &test_segments[0],
+  },
   { NULL, NULL, NULL, 0, 0, 0, { 0 }, 0 },
 };
 
@@ -1212,6 +1227,14 @@
   
   stream_write (peer.ibuf, t->attrheader, t->len);
   datalen = aspath_put (peer.ibuf, asp, t->as4 == AS4_DATA);
+  if (t->old_segment)
+    {
+      char dummyaspath[] = { BGP_ATTR_FLAG_TRANS, BGP_ATTR_AS_PATH,
+                             t->old_segment->len };
+      stream_write (peer.ibuf, dummyaspath, sizeof (dummyaspath));
+      stream_write (peer.ibuf, t->old_segment->asdata, t->old_segment->len);
+      datalen += sizeof (dummyaspath) + t->old_segment->len;
+    }
   
   ret = bgp_attr_parse (&peer, &attr, t->len + datalen, NULL, NULL);
   
@@ -1224,12 +1247,12 @@
   if (ret != 0)
     goto out;
   
-  if (attr.aspath == NULL)
+  if (t->shouldbe && attr.aspath == NULL)
     {
-      printf ("aspath is NULL!\n");
+      printf ("aspath is NULL, but should be: %s\n", t->shouldbe);
       failed++;
     }
-  if (attr.aspath && strcmp (attr.aspath->str, t->shouldbe))
+  if (t->shouldbe && attr.aspath && strcmp (attr.aspath->str, t->shouldbe))
     {
       printf ("attr str and 'shouldbe' mismatched!\n"
               "attr str:  %s\n"
@@ -1237,6 +1260,11 @@
               attr.aspath->str, t->shouldbe);
       failed++;
     }
+  if (!t->shouldbe && attr.aspath)
+    {
+      printf ("aspath should be NULL, but is: %s\n", attr.aspath->str);
+      failed++;
+    }
 
 out:
   if (attr.aspath)
