tests

package
v0.0.0-...-58fa5b2 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2017 License: Apache-2.0 Imports: 4 Imported by: 2

README

tests

import "github.com/ardanlabs/kit/tests"

Overview

Package tests provides the generic support all tests require.

Index

Package files

tests.go

Variables

var (
    Success = "\u2713"
    Failed  = "\u2717"
)

Success and failure markers.

var Logdash bytes.Buffer

Logdash is the central buffer where all logs are stored.

var TraceID = "Test"

TraceID provides a base trace id for tests.

func DisplayLog

func DisplayLog()

DisplayLog writes the Logdash data to standand out, if testing in verbose mode was turned on.

func IndentJSON

func IndentJSON(j string) string

IndentJSON takes a JSON payload as a string and re-indents it to make comparing expected strings to tests strings during testing.

func ResetLog

func ResetLog()

ResetLog resets the contents of Logdash.


Generated by godoc2md

Documentation

Overview

Package tests provides the generic support all tests require.

Index

Constants

This section is empty.

Variables

View Source
var (
	Success = "\u2713"
	Failed  = "\u2717"
)

Success and failure markers.

View Source
var Logdash bytes.Buffer

Logdash is the central buffer where all logs are stored.

View Source
var TraceID = "Test"

TraceID provides a base trace id for tests.

Functions

func DisplayLog

func DisplayLog()

DisplayLog writes the Logdash data to standand out, if testing in verbose mode was turned on.

func IndentJSON

func IndentJSON(j string) string

IndentJSON takes a JSON payload as a string and re-indents it to make comparing expected strings to tests strings during testing.

func ResetLog

func ResetLog()

ResetLog resets the contents of Logdash.

Types

This section is empty.

Jump to

Keyboard shortcuts

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