public void ShouldSerializeDelegates() { // arrange var obj = new FuncAndAction { Action = () => { }, Func = () => "Hello World", }; // act var exception = Record.Exception(() => _serializer.Serialize(obj)); // assert exception.ShouldBeNull(); }