public void TheDicationaryHasValues() { EventHeader sut = GetSut(); var expected = "sdmnfö2342ütäerfd"; sut.Set("foo", expected); Dictionary <string, string> values = sut.ToDictionary(); Assert.Equal(3, values.Count); }
public string SerializeHeader(EventHeader headers) { Precondition.For(headers, nameof(headers)).NotNull(); return(JsonConvert.SerializeObject(headers.ToDictionary(), SerializerSettings)); }
public virtual string SerializeHeader(EventHeader headers) { Precondition.For(headers, nameof(headers)).NotNull(); return(JsonSerializer.Serialize(headers.ToDictionary())); }