Documentation ¶
Index ¶
- Constants
- Variables
- func DownloadDevfileUsingSPI(s SPI, ctx context.Context, component v1alpha1.Component, repoURL string, ...) ([]byte, string, error)
- func DownloadDevfileandDockerfileUsingSPI(s SPI, ctx context.Context, name string, component v1alpha1.Component, ...) ([]byte, []byte, string, error)
- func DownloadFileUsingSPI(s SPI, ctx context.Context, fcrName string, component v1alpha1.Component, ...) ([]byte, error)
- type MockSPIClient
- type SPI
- type SPIClient
- type SPIFileContentRequestError
Constants ¶
View Source
const ( SPIFCR_waiting_for_delivered_phase = "File content request status has not been delivered" SPIFCR_prefix = "spi-fcr-" )
Variables ¶
View Source
var ValidDevfileLocations = cdqanalysis.ValidDevfileLocations
Functions ¶
func DownloadDevfileUsingSPI ¶
Types ¶
type MockSPIClient ¶
func (MockSPIClient) GetFileContents ¶
func (s MockSPIClient) GetFileContents(ctx context.Context, name string, component v1alpha1.Component, repoURL string, filepath string, ref string) (io.ReadCloser, error)
GetFileContents mocks the GetFileContents function from SPI If "repoURL" parameter contains "test-error-response", then an error value will be returned, otherwise we return a mock devfile that can be read.
type SPIFileContentRequestError ¶
type SPIFileContentRequestError struct {
Message string
}
SPIFileContentRequestError returns an internal error
func (*SPIFileContentRequestError) Error ¶
func (e *SPIFileContentRequestError) Error() string
Click to show internal directories.
Click to hide internal directories.