test

package
v0.0.0-...-0190efd Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertInt

func AssertInt(target int, expectation int, t *testing.T) bool

func AssertMultistatusXML

func AssertMultistatusXML(target, expectation string, t *testing.T)

func AssertResourceData

func AssertResourceData(rpath, expectation string, t *testing.T)

func AssertResourceDoesNotExist

func AssertResourceDoesNotExist(rpath string, t *testing.T)

func AssertResourceExists

func AssertResourceExists(rpath string, t *testing.T)

func AssertStr

func AssertStr(target string, expectation string, t *testing.T)

Types

type FakeStorage

type FakeStorage struct {
	data.Storage
}

func NewFakeStorage

func NewFakeStorage() FakeStorage

Creates a fake storage to be used in unit tests. TODO: for now it's just creating a storage based of the default file storage. Would be better having an in-memory storage instead and make use of a stubbed fake storage to make unit tests faster.

func (FakeStorage) AddFakeResource

func (s FakeStorage) AddFakeResource(collection, name, data string)

Jump to

Keyboard shortcuts

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