public void SimpleTest()
        {
            var s = new Sequentializer();
            var results = new List<int>();

            s.Execute(() => results.Add(1));
            s.Execute(() => results.Add(2));

            CollectionAssert.AreEqual(new[] { 1, 2 }, results);
        }
 public void ReentrantTest()
 {
     var s = new Sequentializer();
     var results = new List<int>();
     s.Execute(() => {
         results.Add(1);
         s.Execute(() => results.Add(3));
         results.Add(2);
     });
     CollectionAssert.AreEqual(new[] { 1, 2, 3 }, results);
 }