gitserver

package
v0.21.3 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package gitserver is a stand-in git remote for tests that must prove a token reached the forge it belongs to, without a network or a real forge.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	// Origin is the server's scheme, host and port.
	Origin string
	// contains filtered or unexported fields
}

Server refuses every request with a 401, and records what each one presented.

func New

func New(t *testing.T) *Server

New starts a Server for the length of the test.

func (*Server) Received

func (s *Server) Received(token string) bool

Received reports whether a request presented token as its password.

Jump to

Keyboard shortcuts

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