コード例 #1
0
        public void assign_with_a_value()
        {
            bool assigned = true;

            var generator = new StringIdGeneration();
            generator.Assign("something", out assigned).ShouldBe("something");

            assigned.ShouldBeFalse();
        }
コード例 #2
0
        public void assign_with_a_value()
        {
            bool assigned = true;

            var generator = new StringIdGeneration();

            generator.Assign(null, "something", out assigned).ShouldBe("something");

            assigned.ShouldBeFalse();
        }
コード例 #3
0
        public void assign_when_null()
        {
            bool assigned = true;

            var generator = new StringIdGeneration();


            Exception <InvalidOperationException> .ShouldBeThrownBy(() =>
            {
                generator.Assign(null, null, out assigned);
            });
        }
コード例 #4
0
        public void assign_when_null()
        {
            bool assigned = true;

            var generator = new StringIdGeneration();


            Exception<InvalidOperationException>.ShouldBeThrownBy(() =>
            {
                generator.Assign(null, out assigned);
            });
        }