Commits

Paweł Wieczorek  committed d455d70 Draft

more tests

  • Participants
  • Parent commits c4df3aa

Comments (0)

Files changed (1)

File tests/data/Testdata_messages.ml

                 142
             ]
 
+        ; prepare_valid_message "register from RFC3261.24.1"
+            [ "REGISTER sip:registrar.biloxi.com SIP/2.0"
+            ; "Via: SIP/2.0/UDP bobspc.biloxi.com:5060;branch=z9hG4bKnashds7"
+            ; "Max-Forwards: 70"
+            ; "To: Bob <sip:bob@biloxi.com>"
+            ; "From: Bob <sip:bob@biloxi.com>;tag=456248"
+            ; "Call-ID: 843817637684230@998sdasdh09"
+            ; "CSeq: 1826 REGISTER"
+            ; "Contact: <sip:bob@192.0.2.4>"
+            ; "Expires: 7200"
+            ; "Content-Length: 0"
+            ; ""
+            ; ""
+            ]
 
+            [ descr_sip_method
+                REGISTER
+
+            ; descr_uri
+                (SipUri "sip:registrar.biloxi.com")
+
+            ; descr_sip_version
+                SIP_2_0
+
+            ; descr_max_forwards
+                70
+
+            ; descr_call_id
+                (SipCallId "843817637684230@998sdasdh09")
+
+            ; descr_cseq
+                (SipCseq "1826 REGISTER")
+
+            ; descr_content_length
+                0
+            ]
+
+        ; prepare_valid_message "sip message from RFC3261.24.2 (Alice -> atlanta.com proxy)"
+            [ "INVITE sip:bob@biloxi.com SIP/2.0"
+            ; "Via: SIP/2.0/UDP pc33.atlanta.com;branch=z9hG4bKnashds8"
+            ; "Max-Forwards: 70"
+            ; "To: Bob <sip:bob@biloxi.com>"
+            ; "From: Alice <sip:alice@atlanta.com>;tag=1928301774"
+            ; "Call-ID: a84b4c76e66710"
+            ; "CSeq: 314159 INVITE"
+            ; "Contact: <sip:alice@pc33.atlanta.com>"
+            ; "Content-Type: application/sdp"
+            ; "Content-Length: 142"
+            ; ""
+            ; String.repeat "a" 142
+            ]
+
+            [
+            ]
+
+        ; prepare_valid_message "sip message from RFC3261.24.2 (atlanta.com proxy -> biloxi.com proxy)"
+            [ "INVITE sip:bob@biloxi.com SIP/2.0"
+            ; "Via: SIP/2.0/UDP bigbox3.site3.atlanta.com;branch=z9hG4bK77ef4c2312983.1"
+            ; "Via: SIP/2.0/UDP pc33.atlanta.com;branch=z9hG4bKnashds8"
+            ; " ;received=192.0.2.1"
+            ; "Max-Forwards: 69"
+            ; "To: Bob <sip:bob@biloxi.com>"
+            ; "From: Alice <sip:alice@atlanta.com>;tag=1928301774"
+            ; "Call-ID: a84b4c76e66710"
+            ; "CSeq: 314159 INVITE"
+            ; "Contact: <sip:alice@pc33.atlanta.com>"
+            ; "Content-Type: application/sdp"
+            ; "Content-Length: 142"
+            ; ""
+            ; String.repeat "a" 142
+            ]
+
+            [
+            ]
+
+        ; prepare_valid_message "sip message from RFC3261.24.2 (biloxi.com proxy -> Bob)"
+            [ "INVITE sip:bob@192.0.2.4 SIP/2.0"
+            ; "Via: SIP/2.0/UDP server10.biloxi.com;branch=z9hG4bK4b43c2ff8.1"
+            ; "Via: SIP/2.0/UDP bigbox3.site3.atlanta.com;branch=z9hG4bK77ef4c2312983.1"
+            ; " ;received=192.0.2.2"
+            ; "Via: SIP/2.0/UDP pc33.atlanta.com;branch=z9hG4bKnashds8"
+            ; " ;received=192.0.2.1"
+            ; "Max-Forwards: 68"
+            ; "To: Bob <sip:bob@biloxi.com>"
+            ; "From: Alice <sip:alice@atlanta.com>;tag=1928301774"
+            ; "Call-ID: a84b4c76e66710"
+            ; "CSeq: 314159 INVITE"
+            ; "Contact: <sip:alice@pc33.atlanta.com>"
+            ; "Content-Type: application/sdp"
+            ; "Content-Length: 142"
+            ; ""
+            ; String.repeat "a" 142
+            ]
+
+            [
+            ]
+
+        ; prepare_valid_message "sip message ACK from RFC3261.24.2 (Alice -> Bob)"
+            [ "ACK sip:bob@192.0.2.4 SIP/2.0"
+            ; "Via: SIP/2.0/UDP pc33.atlanta.com;branch=z9hG4bKnashds9"
+            ; "Max-Forwards: 70"
+            ; "To: Bob <sip:bob@biloxi.com>;tag=a6c85cf"
+            ; "From: Alice <sip:alice@atlanta.com>;tag=1928301774"
+            ; "Call-ID: a84b4c76e66710"
+            ; "CSeq: 314159 ACK"
+            ; "Content-Length: 0"
+            ]
+
+            [
+            ]
+
+        ; prepare_valid_message "sip message BYE from RFC3261.24.2 (Bob -> Alice)"
+            [ "BYE sip:alice@pc33.atlanta.com SIP/2.0"
+            ; "Via: SIP/2.0/UDP 192.0.2.4;branch=z9hG4bKnashds10"
+            ; "Max-Forwards: 70"
+            ; "From: Bob <sip:bob@biloxi.com>;tag=a6c85cf"
+            ; "To: Alice <sip:alice@atlanta.com>;tag=1928301774"
+            ; "Call-ID: a84b4c76e66710"
+            ; "CSeq: 231 BYE"
+            ; "Content-Length: 0"
+            ; ""
+            ; ""
+            ]
+
+            [
+            ]
     ]
 
 end