service_packs

package
v0.4.1 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

README

Probes Engineering Notes

This directory contains subdirectories for each service pack within Probr. A service pack contains multiple probes that are designed to verify that the service is in compliance with various controls.

Feature Files

Each probe describes a set of related controls, which are together defined in a single Cucumber BDD .feature file.

For more information on the gherkin language and how a BDD "feature file" is written, please review the Cucumber documentation

Feature Scenarios and Steps

Each control that is to be validated takes the form of a Cucumber scenario. A scenario is executed as a sequence of steps- each of which is described in the feature file as an english language statement, begining with a reserved word (Given, And, When, Then). The functions that define each step can be found in the .go file that has the name of the associated probe. (For example, "container registry access" steps are defined in container_registry_access.go)

Within the probe's go file, functions must be defined to execute each of the steps specified in the corresponding feature file.

For example, the container_registry_access.feature file specifies a step When I attempt to push to the container registry using the cluster identity. Within the container_registry_access.go file, a ScenarioState method iAttemptToPushToTheContainerRegistryUsingTheClusterIdentity is defined and mapped to the string 'I attempt to push to the container registry using the cluster identity'.

Mapping a step to a golang function is registered in the ScenarioContext of the 'godog test handler', so that when the test handler runs a probe for a feature file, it executes the appropriate go code for each defined step. See any ScenarioInitialize function for an example of the registration of step functions.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAllProbes

func GetAllProbes() []*coreengine.GodogProbe

Types

This section is empty.

Directories

Path Synopsis
Package kubernetes provides functions for interacting with Kubernetes and is built using the kubernetes client-go (https://github.com/kubernetes/client-go).
Package kubernetes provides functions for interacting with Kubernetes and is built using the kubernetes client-go (https://github.com/kubernetes/client-go).
container_registry_access
Package container_registry_access provides the implementation required to execute the feature based test cases described in the the 'events' directory.
Package container_registry_access provides the implementation required to execute the feature based test cases described in the the 'events' directory.
general
Package general provides the implementation required to execute the feature-based test cases described in the the 'events' directory.
Package general provides the implementation required to execute the feature-based test cases described in the the 'events' directory.
iam
Provides the implementation required to execute the feature based test cases described in the the 'events' directory.
Provides the implementation required to execute the feature based test cases described in the the 'events' directory.

Jump to

Keyboard shortcuts

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