Exemplo n.º 1
0
        public static void That(Expression <Func <bool> > assertion)
        {
            var exception = AssertImpl.That(assertion, null, null);

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 2
0
        public static async Task Throws <TException>(Expression <Func <Task> > expression) where TException : Exception
        {
            var exception = await AssertImpl.Throws(expression, typeof(TException));

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 3
0
        public static async Task Throws(Expression <Func <Task> > expression)
        {
            var exception = await AssertImpl.Throws(expression);

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 4
0
        public static void Throws <TException>(Expression <Func <object> > expression) where TException : Exception
        {
            var exception = AssertImpl.Throws(expression, typeof(TException));

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 5
0
        public static void Throws(Expression <Action> expression)
        {
            var exception = AssertImpl.Throws(expression);

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 6
0
        public static void That(Expression <Func <bool> > assertion, object message, Expression <Func <object> > context)
        {
            var exception = AssertImpl.That(assertion, message, context);

            if (exception != null)
            {
                throw exception;
            }
        }
Exemplo n.º 7
0
        public static void Assert(Expression <Func <bool> > assertion, object message)
        {
            var exception = AssertImpl.That(assertion, message, null);

            if (exception != null)
            {
                throw exception;
            }
        }