public static IResponse Header(this IHas @this, string name, string value)
        {
            @this.AssertPositive(AssertHeaderValueEqual(name, value));
            @this.AssertNegative(AssertHeaderValueNotEqual(name, value));

            return((IResponse)@this);
        }
        public static IResponse Xml(this IHas @this, XDocument content)
        {
            @this.AssertPositive(AssertContentEqual(content));
            @this.AssertNegative(AssertContentNotEqual(content));

            return((IResponse)@this);
        }
        public static IResponse Header(this IHas @this, string name)
        {
            @this.AssertPositive(AssertHeaderExists(name));
            @this.AssertNegative(AssertHeaderDoesNotExist(name));

            return((IResponse)@this);
        }
        public static IResponse String(this IHas @this, string content)
        {
            @this.AssertPositive(AssertContentEqual(content));
            @this.AssertNegative(AssertContentNotEqual(content));

            return((IResponse)@this);
        }
        public static IResponse Json <T>(this IHas @this, T content)
        {
            @this.AssertPositive(AssertContentEqual(content));
            @this.AssertNegative(AssertContentNotEqual(content));

            return((IResponse)@this);
        }
        public static IResponse ByteArray(this IHas @this, byte[] content)
        {
            @this.AssertPositive(AssertContentEqual(content));
            @this.AssertNegative(AssertContentNotEqual(content));

            return((IResponse)@this);
        }
        public static IResponse Content(this IHas @this)
        {
            @this.AssertPositive(AssertContentExists);
            @this.AssertNegative(AssertContentDoesNotExist);

            return((IResponse)@this);
        }
Exemple #8
0
        public static IResponse Status(this IHas @this, int statusCode)
        {
            @this.AssertPositive(AssertStatusEqual(statusCode));
            @this.AssertNegative(AssertStatusNotEqual(statusCode));

            return((IResponse)@this);
        }
Exemple #9
0
        public static IResponse Version(this IHas @this, Version version)
        {
            @this.AssertPositive(AssertVersionEqual(version));
            @this.AssertNegative(AssertVersionNotEqual(version));

            return((IResponse)@this);
        }
        public static IResponse ReasonPhrase(this IHas @this, string reasonPhrase)
        {
            @this.AssertPositive(AssertReasonPhraseEqual(reasonPhrase));
            @this.AssertNegative(AssertReasonPhraseNotEqual(reasonPhrase));

            return((IResponse)@this);
        }