summaryrefslogtreecommitdiffstats
path: root/openecomp-bdd/stepDefinitions/Item_steps.js
diff options
context:
space:
mode:
Diffstat (limited to 'openecomp-bdd/stepDefinitions/Item_steps.js')
-rw-r--r--openecomp-bdd/stepDefinitions/Item_steps.js24
1 files changed, 24 insertions, 0 deletions
diff --git a/openecomp-bdd/stepDefinitions/Item_steps.js b/openecomp-bdd/stepDefinitions/Item_steps.js
index 165df6ca30..3ff7f20f73 100644
--- a/openecomp-bdd/stepDefinitions/Item_steps.js
+++ b/openecomp-bdd/stepDefinitions/Item_steps.js
@@ -65,3 +65,27 @@ Then('I want to revert this Item to the revision with the value from saved prope
return util.request(this.context, 'PUT', path, inputData);
});
+
+/**
+ * @module Item
+ * @exampleFile ArchiveItem.feature
+ * @step I want to archive this item
+ **/
+Then('I want to archive this item', function() {
+ let path = '/items/' + this.context.item.id + '/actions'
+ let inputData = {action: 'ARCHIVE'};
+ return util.request(this.context, 'PUT', path, inputData);
+});
+
+
+/**
+ * @module Item
+ * @exampleFile ArchiveItem.feature
+ * @step I want to restore this item
+ **/
+Then('I want to restore this item', function() {
+ let path = '/items/' + this.context.item.id + '/actions'
+ let inputData = {action: 'RESTORE'};
+ return util.request(this.context, 'PUT', path, inputData);
+});
+