fake

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2026 License: Apache-2.0 Imports: 3 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package fake provides an in-memory sourcecontrol.SourceControl seeded with a single queue's linear ref history, ordered newest-first. It is intended for examples and tests only, never production. Ancestry is decided by position in the seeded slice: an earlier commit (larger index) is an ancestor of a later one (smaller index).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(history []string) sourcecontrol.SourceControl

New returns a sourcecontrol.SourceControl backed by the given ref history, ordered newest-first (history[0] is the latest commit). The slice is copied so later mutation by the caller does not affect the fake.

Types

This section is empty.

Jump to

Keyboard shortcuts

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