Fix failing test cases and add missing doc snippets.
This commit is contained in:
@@ -226,9 +226,7 @@ public class PipelineYmlSchema implements YamlSchema {
|
||||
AbstractType t_image_resource = f.ybean("ImageResource");
|
||||
{
|
||||
Map<String, YTypedProperty> resourceProperties = t_resource.getPropertiesMap();
|
||||
//Some of the properties in 'image_resource' are just like the ones in regular resource.
|
||||
// So let's copy them...
|
||||
t_image_resource.addProperty(resourceProperties.get("type"));
|
||||
addProp(t_image_resource, "type", t_resource_type_name).isRequired(true);
|
||||
t_image_resource.addProperty(resourceProperties.get("source"));
|
||||
addProp(t_image_resource, "params", t_params);
|
||||
//TODO: make ImageResourceParams dynamic based on resource type. Somewhat like below, but that code isn't exactly
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
*Optional.* A map of arbitrary configuration to forward to the resource. Refer to the resource type's documentation to see what it supports.
|
||||
@@ -0,0 +1 @@
|
||||
*Required.* The type of the resource. Usually `docker-image`.
|
||||
@@ -0,0 +1 @@
|
||||
Optional. A specific version of the resource to fetch. This should be a map with string keys and values. If not specified, the latest version will be fetched.
|
||||
@@ -4251,12 +4251,13 @@ public class ConcourseEditorTest {
|
||||
" path: blah\n" +
|
||||
"image_resource:\n" +
|
||||
" type: docker-image\n" +
|
||||
" params: {}\n" +
|
||||
" source:\n" +
|
||||
" repository: some-docker-image\n" +
|
||||
" version: latest"
|
||||
);
|
||||
editor.assertHoverContains("type", "type of the resource. Usually `docker-image`.");
|
||||
editor.assertHoverContains("source", "Configuration for the resource");
|
||||
editor.assertHoverContains(" source", "The location of the resource");
|
||||
editor.assertHoverContains("params", "A map of arbitrary configuration to forward to the resource");
|
||||
editor.assertHoverContains("version", "A specific version of the resource to fetch");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user