Skip to content

nitroshare/compare

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

compare

Build Status Coverage Status Go Reference MIT License

This package provides a simple utility function for comparing values in a test. The goal is extreme simplicity:

import (
    "testing"

    "github.com/nitroshare/compare"
)

func TestSomething(t *testing.T) {

    // Second and third parameter are compared and the fourth parameter
    // determines if they should match; in this case, they should...
    compare.Compare(t, 1, 1, true)

    // ...and in this case they should not
    compare.Compare(t, 1, 2, false)
}

About

Simple utility function for comparing values in a test

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages