Skip to content

assert.IsIncreasing can return false without failing the test #1419

Description

@brackendawson

go.dev/play

package main

import (
	"testing"

	"github.com/stretchr/testify/assert"
)

func Test(t *testing.T) {
	if !assert.IsIncreasing(t, 0) {
		t.Log("assertion is false, test should fail")
	}
}

yields

=== RUN   Test
    prog_test.go:11: assertion is false, test should fail
--- PASS: Test (0.00s)
PASS

#1124 would fix this.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions