Exemple #1
0
        protected override void ExpectResponse(ISearchResponse <Project> response)
        {
            response.ShouldNotBeValid();
            var serverError = response.ServerError;

            serverError.Should().NotBeNull();
            serverError.Status.Should().Be(400);
            serverError.Error.Reason.Should().Be("all shards failed");
            serverError.Error.RootCause.First().Reason.Should().Contain("[-1m]");
        }
        protected override void ExpectResponse(ISearchResponse <Project> response)
        {
            response.ShouldNotBeValid();
            var serverError = response.ServerError;

            serverError.Should().NotBeNull();
            serverError.Status.Should().Be(ExpectStatusCode);
            serverError.Error.Reason.Should().Be("all shards failed");
            serverError.Error.RootCause.First().Reason.Should().Contain("value source config is invalid");
        }
        protected override void ExpectResponse(ISearchResponse <Project> response)
        {
            response.ShouldNotBeValid();
            var serverError = response.ServerError;

            serverError.Should().NotBeNull();
            serverError.Status.Should().Be(ExpectStatusCode, "{0}", response.DebugInformation);

            serverError.Error.Type.Should().Be("illegal_argument_exception");
            serverError.Error.RootCause.First().Reason.Should().Contain("Required one of fields");
        }
Exemple #4
0
        protected override void ExpectResponse(ISearchResponse <Project> response)
        {
            response.ShouldNotBeValid();

            response.ServerError.Should().NotBeNull();
            response.ServerError.Status.Should().Be(400);
            response.ServerError.Error.Should().NotBeNull();
            var rootCauses = response.ServerError.Error.RootCause;

            rootCauses.Should().NotBeNullOrEmpty();
            var rootCause = rootCauses.First();

            rootCause.Type.Should().Be("parsing_exception");
        }
Exemple #5
0
 protected override void ExpectResponse(ISearchResponse <Project> response) => response.ShouldNotBeValid();