public async void EmptyContext()
        {
            var context = new DefaultHttpContext();

            context.Request.Body        = new MemoryStream();
            context.Request.ContentType = "application/x-www-form-urlencoded";

            var secret = await _parser.ParseAsync(context);

            secret.Should().BeNull();
        }
Example #2
0
        public async void EmptyOwinEnvironment()
        {
            var context = new OwinContext();

            context.Request.Body = new MemoryStream();

            var secret = await _parser.ParseAsync(context.Environment);

            secret.Should().BeNull();
        }