testresources

package
v0.0.0-...-84fd5d0 Latest Latest
Warning

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

Go to latest
Published: Mar 24, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Image1 = func() *apiv2.Image {
		return &apiv2.Image{
			Id:             "ubuntu-24.04",
			Name:           new("Ubuntu 24.04"),
			Description:    new("Ubuntu 24.04 LTS"),
			Features:       []apiv2.ImageFeature{apiv2.ImageFeature_IMAGE_FEATURE_MACHINE},
			Classification: apiv2.ImageClassification_IMAGE_CLASSIFICATION_SUPPORTED,
		}
	}
	Image2 = func() *apiv2.Image {
		return &apiv2.Image{
			Id:             "firewall-3.0",
			Name:           new("Firewall 3.0"),
			Description:    new("Metal Firewall"),
			Features:       []apiv2.ImageFeature{apiv2.ImageFeature_IMAGE_FEATURE_FIREWALL},
			Classification: apiv2.ImageClassification_IMAGE_CLASSIFICATION_PREVIEW,
		}
	}
)
View Source
var (
	IP1 = func() *apiv2.IP {
		return &apiv2.IP{
			Uuid:        "2e0144a2-09ef-42b7-b629-4263295db6e8",
			Network:     "internet",
			Ip:          "1.1.1.1",
			Name:        "a",
			Description: "a description",
			Project:     "ce19a655-7933-4745-8f3e-9592b4a90488",
			Type:        apiv2.IPType_IP_TYPE_STATIC,
			Meta: &apiv2.Meta{
				Labels: &apiv2.Labels{
					Labels: map[string]string{
						tag.ClusterServiceFQN: "<cluster>/default/ingress-nginx",
					},
				},
			},
		}
	}
	IP2 = func() *apiv2.IP {
		return &apiv2.IP{
			Uuid:        "9cef40ec-29c6-4dfa-aee8-47ee1f49223d",
			Network:     "internet",
			Ip:          "4.3.2.1",
			Name:        "b",
			Description: "b description",
			Project:     "46bdfc45-9c8d-4268-b359-b40e3079d384",
			Type:        apiv2.IPType_IP_TYPE_EPHEMERAL,
			Meta: &apiv2.Meta{
				Labels: &apiv2.Labels{
					Labels: map[string]string{
						"a": "b",
					},
				},
			},
		}
	}
)
View Source
var (
	Project1 = func() *apiv2.Project {
		return &apiv2.Project{
			Uuid:        "0d81bca7-73f6-4da3-8397-4a8c52a0c583",
			Name:        "project-a",
			Description: "first project",
			Tenant:      "metal-stack",
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
	Project2 = func() *apiv2.Project {
		return &apiv2.Project{
			Uuid:        "f3b4e6a1-2c8d-4e5f-a7b9-1d3e5f7a9b0c",
			Name:        "project-b",
			Description: "second project",
			Tenant:      "metal-stack",
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
)
View Source
var (
	Tenant1 = func() *apiv2.Tenant {
		return &apiv2.Tenant{
			Login:       "metal-stack",
			Name:        "Metal Stack",
			Email:       "info@metal-stack.io",
			Description: "a tenant",
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
	Tenant2 = func() *apiv2.Tenant {
		return &apiv2.Tenant{
			Login:       "acme-corp",
			Name:        "ACME Corp",
			Email:       "admin@acme.io",
			Description: "another tenant",
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
)
View Source
var (
	Token1 = func() *apiv2.Token {
		return &apiv2.Token{
			Uuid:        "a3b1f6d2-4e8c-4f7a-9d2e-1b5c8f3a7e90",
			User:        "admin@metal-stack.io",
			Description: "ci token",
			TokenType:   apiv2.TokenType_TOKEN_TYPE_API,
			Expires:     timestamppb.New(e2e.TimeBubbleStartTime().Add(24 * time.Hour)),
			IssuedAt:    timestamppb.New(e2e.TimeBubbleStartTime()),
			Permissions: nil,
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
	Token2 = func() *apiv2.Token {
		return &apiv2.Token{
			Uuid:        "b4c2e7f3-5a9d-4b8e-a1c3-2d6f9e4b8a01",
			User:        "dev@metal-stack.io",
			Description: "dev token",
			TokenType:   apiv2.TokenType_TOKEN_TYPE_API,
			Expires:     timestamppb.New(e2e.TimeBubbleStartTime().Add(48 * time.Hour)),
			IssuedAt:    timestamppb.New(e2e.TimeBubbleStartTime()),
			Permissions: nil,
			Meta: &apiv2.Meta{
				CreatedAt: timestamppb.New(e2e.TimeBubbleStartTime()),
			},
		}
	}
)

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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