tests

package
v1.9.26 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateNpmTest

func CreateNpmTest(t *testing.T, testdataPath, projectDirName string, withOsInPath bool, version *version.Version) (tmpProjectPath string, cleanup func())

Return the project path based on 'projectDir'. withOsInPath - some tests have individual cases for specific os, if true, return the tests for that belong to the current running os. testdataPath - abs path to testdata dir. projectDirName - name of the project's directory.

func CreateTempDirWithCallbackAndAssert

func CreateTempDirWithCallbackAndAssert(t *testing.T) (string, func())

func CreateTestProject

func CreateTestProject(t *testing.T, projectPath string) (tmpProjectPath string, cleanup func())

Copy a project from path to temp dir. projectPath - Local path to a project Return the copied project location and a cleanup function to delete it.

func GetBuildInfo

func GetBuildInfo(t *testing.T, filePath string) entities.BuildInfo

func PrintBuildInfoMismatch

func PrintBuildInfoMismatch(t *testing.T, expected, actual []entities.Module)

Types

This section is empty.

Jump to

Keyboard shortcuts

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