Skip to content

The error is not accurately describe #28

Closed
@njspok

Description

Very nice library! But there is one drawback.

Run this test

package baloo

import (
	"gopkg.in/h2non/baloo.v3"
	"testing"
)

func Test(t *testing.T) {
	b := baloo.New("http://www.ya.ru")
	_ = b.Get(".").Expect(t).Status(11).Done()
	_ = b.Get(".").Expect(t).Status(11).Done()
	_ = b.Get(".").Expect(t).Status(11).Done()
}

Look result

=== RUN   Test
--- FAIL: Test (0.35s)
    expect.go:204: Unexpected status code: 404 != 11
    expect.go:204: Unexpected status code: 404 != 11
    expect.go:204: Unexpected status code: 404 != 11
FAIL

Process finished with exit code 1

There is no way to know exactly where the test failed. The error message point inside the library

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions