Beispiel #1
0
        public void HandleNotify_AllHeaders_ShouldParseRelevantHeader()
        {
            GenaNotifyResponse result = _parser.Parse(_validHeaders, _validBodyStringWithSingleValue);

            Assert.Equal("SomeSID", result.SubscriptionId);
            Assert.Equal("SomeNTS", result.NTS);
            Assert.Equal(2, result.SequencyNumber);
        }
Beispiel #2
0
 private void HandleOnNotify(object sender, GenaNotifyResponse e)
 {
     LastEvent = new UPnPServiceEvent(e.Values);
     OnNewEvent?.Invoke(this, LastEvent);
 }
Beispiel #3
0
        public void HandleNotify_BodyWithSingleValue_ValueShouldBeWrittenToSubscriber()
        {
            GenaNotifyResponse result = _parser.Parse(_validHeaders, _validBodyStringWithSingleValue);

            Assert.True(result.Values.Contains(new KeyValuePair <string, string>("LastChange", "SomeValue")));
        }