hal

package module
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2019 License: MIT Imports: 4 Imported by: 8

Documentation

Overview

Package hal separate depends on on real hardware and os, such as time, file, and other os operations. Use hal package mainly for easier to do unit test.

Nearly all members in this package is unprotected alias of standard go functions, do not alter them unless inside unit tests.

Index

Constants

This section is empty.

Variables

View Source
var (
	// Exit is alias of os.Exit
	Exit = os.Exit

	// Now is alias of time.Now
	Now = time.Now

	// Getenv is alias of os.Getenv
	Getenv = os.Getenv

	// CurrentUser is alias of os/user.Current
	CurrentUser = user.Current
)

Functions

This section is empty.

Types

This section is empty.

Directories

Path Synopsis
Package timeth provide a hal.Time implementation, for easier to set/tick current mock time.
Package timeth provide a hal.Time implementation, for easier to set/tick current mock time.

Jump to

Keyboard shortcuts

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