testutil

package
v0.0.0-...-0871eb3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 4, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package testutil is utility for test

Index

Constants

This section is empty.

Variables

View Source
var (
	//LogFlg is for switch to output log or not
	LogFlg = flag.Uint("log", 1, "Log Flg: 0:OFF, 1:ON")
	//ConfFile is toml file path
	ConfFile = flag.String("fp", "", "Config File Path")
	//JSONFile is json file path
	JSONFile = flag.String("jfp", "", "Json File Path")
	//YAMLFile is json file path
	YAMLFile = flag.String("yfp", "", "YAML File Path")

	//KafkaIP is IP for kafka server
	KafkaIP = flag.Int("kip", 9092, "Json File Path")

	//BenchFlg is when benchmark test, value is true
	BenchFlg = false
)

Functions

func InitializeTest

func InitializeTest(prefix string)

InitializeTest is to run common initial code for test

func Log

func Log(t *testing.T, args ...interface{})

Log is t.Log()

tu.Log(t, mRet)

func Logf

func Logf(t *testing.T, format string, args ...interface{})

Logf is t.Logf()

tu.Logf(t, "%+v", mRet)

func SkipBLog

func SkipBLog(b *testing.B)

SkipBLog is to skip test with func name

func SkipLog

func SkipLog(t *testing.T)

SkipLog is to skip test with func name

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL