with_gocheck

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2014 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Implements an on-failure-only gocheck package logger.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StartGoCheckLogger

func StartGoCheckLogger(c *gocheck.C)

Convenience method to initialize rlog with a single (error-level) gocheck logger and start rlog. Can be called at the start of your test method or in your test setup. Remember to put "defer rlog.Flush()" either in your test method(s) or test teardown method. The test teardown is invoked before the success/failure of the gocheck test is evaluated.

Types

type GoCheckLogger

type GoCheckLogger struct {
	// contains filtered or unexported fields
}

Test logger that works for any test harness built on top of testing package.

func NewGoCheckLogger

func NewGoCheckLogger(c *gocheck.C) *GoCheckLogger

Creates a logger using gocheck object.

t: testing object

return: instance of test logger

func (*GoCheckLogger) LaunchModule

func (self *GoCheckLogger) LaunchModule(dataChan <-chan (*common.RlogMsg), flushChan chan (chan (bool)))

Intended to run in a separate goroutine. It prints log messages to console.

dataChan: receives log messages.

flushChan: receives flush command.

Jump to

Keyboard shortcuts

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