From 92fbaa6a5ebe0f91fa5ff5312da4938c393d13e1 Mon Sep 17 00:00:00 2001 From: Wendy Nestor Date: Fri, 14 Mar 2014 11:50:12 -0400 Subject: [PATCH] Reorganizacion de carpetas y avance de los behat para ordenamiento --- .../basic_sequence_case_note.feature | 68 +++++++++ .../basic_sequence_case_variables.feature | 31 ++++ .../basic_sequence_cases_actions_7_12.feature | 0 .../main_tests_cases_actions_7_12.feature | 0 .../negative_tests_cases_actions_7_12.feature | 0 ...basic_sequence_cases_actions_13_17.feature | 0 .../main_tests_cases_actions_13_17.feature | 0 ...negative_tests_cases_actions_13_17.feature | 0 .../basic_sequence_cases_lists_1_6.feature | 42 +++++ ...basic_sequence_input_document_case.feature | 47 ++++++ ...asic_sequence_output_document_case.feature | 47 ++++++ ...main_tests_supervisor_ordenamiento.feature | 144 ++++++++++++++++++ ... basic_sequence_step_ordenamiento.feature} | 0 .../step/main_tests_step_ordenamiento.feature | 85 +++++++++++ 14 files changed, 464 insertions(+) delete mode 100644 features/backend/application_cases/cases actions1 7-12/basic_sequence_cases_actions_7_12.feature delete mode 100644 features/backend/application_cases/cases actions1 7-12/main_tests_cases_actions_7_12.feature delete mode 100644 features/backend/application_cases/cases actions1 7-12/negative_tests_cases_actions_7_12.feature delete mode 100644 features/backend/application_cases/cases actions2 13-17/basic_sequence_cases_actions_13_17.feature delete mode 100644 features/backend/application_cases/cases actions2 13-17/main_tests_cases_actions_13_17.feature delete mode 100644 features/backend/application_cases/cases actions2 13-17/negative_tests_cases_actions_13_17.feature create mode 100644 features/backend/projects/process_supervisor/main_tests_supervisor_ordenamiento.feature rename features/backend/projects/step/{reordenamiento.feature => basic_sequence_step_ordenamiento.feature} (100%) create mode 100644 features/backend/projects/step/main_tests_step_ordenamiento.feature diff --git a/features/backend/application_cases/case note/basic_sequence_case_note.feature b/features/backend/application_cases/case note/basic_sequence_case_note.feature index e69de29bb..0ac95ecdd 100644 --- a/features/backend/application_cases/case note/basic_sequence_case_note.feature +++ b/features/backend/application_cases/case note/basic_sequence_case_note.feature @@ -0,0 +1,68 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Cases Notes +Requirements: + a workspace with three cases of the process "Test Users-Step-Properties End Point" + +Background: + Given that I have a valid access_token + + +Scenario: List of case notes for this case + Given I request "case/{uid}/notes" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + + +Scenario: create a new case note for specified case + Given POST this data: + """ + { + + + + } + """ + And I request "case/{uid}/case" + Then the response status code should be 201 + And the response charset is "UTF-8" + And the content type is "application/json" + And the type is "object" + And store "" in session array + + +Scenario: Get a specified case note for this case + Given that I want to get a resource with the key "" stored in session array + Given I request "case/{uid}/note/{uid}" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the " property equals "" + And the "" property equals "" + + + +Scenario: Modify a case note for specified case + Given PUT this data: + """ + { + + + + } + """ + And that I want to update a resource with the key "" stored in session array + And I request "case/{uid}/case/{uid}" + Then the response status code should be 200 + And the content type is "application/json" + And the response charset is "UTF-8" + And the type is "object" + + +Scenario: Delete a case note for specified case + Given that I want to delete a resource with the key "" stored in session array + And I request "case/{uid}/case/{uid}" + Then the response status code should be 200 + And the content type is "application/json" + And the response charset is "UTF-8" + And the type is "object" diff --git a/features/backend/application_cases/case variables/basic_sequence_case_variables.feature b/features/backend/application_cases/case variables/basic_sequence_case_variables.feature index e69de29bb..7c651c85e 100644 --- a/features/backend/application_cases/case variables/basic_sequence_case_variables.feature +++ b/features/backend/application_cases/case variables/basic_sequence_case_variables.feature @@ -0,0 +1,31 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Cases Variables +Requirements: + a workspace with five cases of the process "Test micheangelo" and "Test Users-Step-Properties End Point" + +Background: + Given that I have a valid access_token + + +Scenario: Returns the variables can be system variables and/or case variables. + Given I request "case/{uid}/get-variables" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Sends variables to a case + Given PUT this data: + """ + { + + + + } + """ + And that I want to update a resource with the key "" stored in session array + And I request "case/{uid}/send-variables" + Then the response status code should be 200 + And the content type is "application/json" + And the response charset is "UTF-8" + And the type is "object" \ No newline at end of file diff --git a/features/backend/application_cases/cases actions1 7-12/basic_sequence_cases_actions_7_12.feature b/features/backend/application_cases/cases actions1 7-12/basic_sequence_cases_actions_7_12.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases actions1 7-12/main_tests_cases_actions_7_12.feature b/features/backend/application_cases/cases actions1 7-12/main_tests_cases_actions_7_12.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases actions1 7-12/negative_tests_cases_actions_7_12.feature b/features/backend/application_cases/cases actions1 7-12/negative_tests_cases_actions_7_12.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases actions2 13-17/basic_sequence_cases_actions_13_17.feature b/features/backend/application_cases/cases actions2 13-17/basic_sequence_cases_actions_13_17.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases actions2 13-17/main_tests_cases_actions_13_17.feature b/features/backend/application_cases/cases actions2 13-17/main_tests_cases_actions_13_17.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases actions2 13-17/negative_tests_cases_actions_13_17.feature b/features/backend/application_cases/cases actions2 13-17/negative_tests_cases_actions_13_17.feature deleted file mode 100644 index e69de29bb..000000000 diff --git a/features/backend/application_cases/cases lists 1-6/basic_sequence_cases_lists_1_6.feature b/features/backend/application_cases/cases lists 1-6/basic_sequence_cases_lists_1_6.feature index e69de29bb..d4a1d8ea9 100644 --- a/features/backend/application_cases/cases lists 1-6/basic_sequence_cases_lists_1_6.feature +++ b/features/backend/application_cases/cases lists 1-6/basic_sequence_cases_lists_1_6.feature @@ -0,0 +1,42 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Cases Actions - the features in this script are (inbox, draftCaseList, participatedCaseList, unassignedCaseList, pausedCaseList and advanced Search) +Requirements: + a workspace with five cases of the process "Test micheangelo" and "Test Users-Step-Properties End Point" + +Background: + Given that I have a valid access_token + + +Scenario: Returns a list of the cases for the logged in user (Inbox) + Given I request "cases" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns a list of the cases for the logged in user (Draft) + Given I request "cases/draft" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns a list of the cases for the logged in user (Participated) + Given I request "cases/participated" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns a list of the cases for the logged in user (Unassigned) + Given I request "cases/unassigned" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns a list of the cases for the logged in user (Paused) + Given I request "cases/paused" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" \ No newline at end of file diff --git a/features/backend/application_cases/input documents_case/basic_sequence_input_document_case.feature b/features/backend/application_cases/input documents_case/basic_sequence_input_document_case.feature index e69de29bb..94ae0389b 100644 --- a/features/backend/application_cases/input documents_case/basic_sequence_input_document_case.feature +++ b/features/backend/application_cases/input documents_case/basic_sequence_input_document_case.feature @@ -0,0 +1,47 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Input Documents cases +Requirements: + a workspace with three cases of the process "Test Users-Step-Properties End Point" + +Background: + Given that I have a valid access_token + + +Scenario: Returns a list of the uploaded documents for a given case + Given I request "case{uid}/input-documents" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns an uploaded documents for a given case + Given I request "case/{uid}/input-document/{uid}" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Post metadata and then upload documents for a given case + Given POST this data: + """ + { + + + + } + """ + And I request "case/{uid}/input-document" + Then the response status code should be 201 + And the response charset is "UTF-8" + And the content type is "application/json" + And the type is "object" + And store "" in session array + + +Scenario: Delete an uploaded or generated document from a case. + Given that I want to delete a resource with the key "" stored in session array + And I request "case/{uid}/input-document/{uid}" + Then the response status code should be 200 + And the content type is "application/json" + And the response charset is "UTF-8" + And the type is "object" diff --git a/features/backend/application_cases/output document_case/basic_sequence_output_document_case.feature b/features/backend/application_cases/output document_case/basic_sequence_output_document_case.feature index e69de29bb..1d3e71069 100644 --- a/features/backend/application_cases/output document_case/basic_sequence_output_document_case.feature +++ b/features/backend/application_cases/output document_case/basic_sequence_output_document_case.feature @@ -0,0 +1,47 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Output Documents cases +Requirements: + a workspace with three cases of the process "Test Users-Step-Properties End Point" + +Background: + Given that I have a valid access_token + + +Scenario: Returns a list of the generated documents for a given case + Given I request "case{uid}/output-documents" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Returns an uploaded documents for a given case + Given I request "case/{uid}/output-document/{uid}" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "array" + + +Scenario: Generate or regenerates an output documents for a given case + Given POST this data: + """ + { + + + + } + """ + And I request "case/{uid}/output-document" + Then the response status code should be 201 + And the response charset is "UTF-8" + And the content type is "application/json" + And the type is "object" + And store "" in session array + + +Scenario: Delete an uploaded or generated document from a case. + Given that I want to delete a resource with the key "" stored in session array + And I request "output-document/{uid}" + Then the response status code should be 200 + And the content type is "application/json" + And the response charset is "UTF-8" + And the type is "object" diff --git a/features/backend/projects/process_supervisor/main_tests_supervisor_ordenamiento.feature b/features/backend/projects/process_supervisor/main_tests_supervisor_ordenamiento.feature new file mode 100644 index 000000000..dc40d1533 --- /dev/null +++ b/features/backend/projects/process_supervisor/main_tests_supervisor_ordenamiento.feature @@ -0,0 +1,144 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Reorder Process Supervisor - Dynaform and Input +Requirements: + a workspace with the process 7557786515322022952dcc8014985410 ("Ordenamiento") already loaded + there are two activities and eight steps in the process + + Background: + Given that I have a valid access_token + + + Scenario Outline: obtain the position of dynaform in process supervisor + Given I request "project/7557786515322022952dcc8014985410/process-supervisors" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "pud_position" is set to "" + + Examples: + + | test_description | step_uid | pud_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 1 | + | Position-dynaform2 | 30547852753220293960227013371359 | 2 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 3 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 4 | + + + Scenario: Change order the dynaform of "dynaform3" by position one + Given PUT this data: + """ + { + "pud_position": "1" + } + """ + And I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/840380819532202d132fb91020992676" + Then the response status code should be 200 + + + Scenario Outline: Obtain the position of the steps after changing position + Given I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "step_position" is set to "" + + Examples: + + | test_description | step_uid | step_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 2 | + | Position-dynaform2 | 30547852753220293960227013371359 | 3 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 1 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 4 | + + + + Scenario Outline: Assign a dynaform to a process supervisor + Given POST this data: + """ + { + "dyn_uid": "" + } + """ + And I request "project/7557786515322022952dcc8014985410/process-supervisor/dynaform" + Then the response status code should be 201 + And the response charset is "UTF-8" + And the content type is "application/json" + And the type is "object" + And store "pud_uid" in session array as variable "pud_uid_" + + + Examples: + | test_description | pud_number | dyn_uid | + | Assign a dynaform5 for Supervisor | 1 | 240449806532203ef307192024451548 | + + + Scenario Outline: Obtain the position of the steps after add new dynaform + Given I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "step_position" is set to "" + + Examples: + + | test_description | step_uid | step_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 2 | + | Position-dynaform2 | 30547852753220293960227013371359 | 3 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 1 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 4 | + | Position-dynaform5 | 240449806532203ef307192024451548 | 5 | + + + Scenario Outline: Delete an dynaform5 to a process supervisor + Given that I want to delete a resource with the key "pui_uid" stored in session array as variable "pud_uid_" + And I request "project//process-supervisor/dynaform" + Then the response status code should be 200 + And the response charset is "UTF-8" + + + Examples: + | test_description | project | pud_number | + | Delete dynaform5 for Supervisor | 7557786515322022952dcc8014985410 | 1 | + + + +Scenario Outline: obtain the position of Input Documents in process supervisor + Given I request "project/7557786515322022952dcc8014985410/process-supervisors" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "pui_position" is set to "" + + Examples: + + | test_description | step_uid | pud_position | + | Position-Input1 | 853418037532209018ab711041079957 | 1 | + | Position-Input2 | 5384383215322090e71aef1047228013 | 2 | + | Position-Input3 | 17499504253220917664c33090176996 | 3 | + + + + Scenario: Change order the Input document of "Input3" by position one + Given PUT this data: + """ + { + "pud_position": "1" + } + """ + And I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/17499504253220917664c33090176996" + Then the response status code should be 200 + + + Scenario Outline: Obtain the position of the steps after changing position + Given I request "project/7557786515322022952dcc8014985410/process-supervisors" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "pui_position" is set to "" + + Examples: + + | test_description | step_uid | pud_position | + | Position-Input1 | 853418037532209018ab711041079957 | 2 | + | Position-Input2 | 5384383215322090e71aef1047228013 | 3 | + | Position-Input3 | 17499504253220917664c33090176996 | 1 | \ No newline at end of file diff --git a/features/backend/projects/step/reordenamiento.feature b/features/backend/projects/step/basic_sequence_step_ordenamiento.feature similarity index 100% rename from features/backend/projects/step/reordenamiento.feature rename to features/backend/projects/step/basic_sequence_step_ordenamiento.feature diff --git a/features/backend/projects/step/main_tests_step_ordenamiento.feature b/features/backend/projects/step/main_tests_step_ordenamiento.feature new file mode 100644 index 000000000..9dbd760c1 --- /dev/null +++ b/features/backend/projects/step/main_tests_step_ordenamiento.feature @@ -0,0 +1,85 @@ +@ProcessMakerMichelangelo @RestAPI +Feature: Reorder Steps +Requirements: + a workspace with the process 7557786515322022952dcc8014985410 ("Ordenamiento") already loaded + there are two activities and eight steps in the process + + Background: + Given that I have a valid access_token + + + Scenario Outline: obtain the position of the steps + Given I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "step_position" is set to "" + + Examples: + + | test_description | step_uid | step_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 1 | + | Position-dynaform2 | 30547852753220293960227013371359 | 2 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 3 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 4 | + | Position-input1 | 853418037532209018ab711041079957 | 5 | + | Position-input2 | 5384383215322090e71aef1047228013 | 6 | + + + Scenario: Change order the step of "dynaform3" by position five + Given PUT this data: + """ + { + "step_position": "5" + } + """ + And I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/840380819532202d132fb91020992676" + Then the response status code should be 200 + + + Scenario Outline: Obtain the position of the steps after changing position + Given I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "step_position" is set to "" + + Examples: + + | test_description | step_uid | step_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 1 | + | Position-dynaform2 | 30547852753220293960227013371359 | 2 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 3 | + | Position-input1 | 853418037532209018ab711041079957 | 4 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 5 | + | Position-input2 | 5384383215322090e71aef1047228013 | 6 | + + + + Scenario: Change order the step of "input2"= position 6 by position two + Given PUT this data: + """ + { + "step_position": "2" + } + """ + And I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/5384383215322090e71aef1047228013" + Then the response status code should be 200 + + + Scenario Outline: Obtain the position of the steps after changing position + Given I request "project/7557786515322022952dcc8014985410/activity/7976552835322023005e069088446535/step/" + Then the response status code should be 200 + And the response charset is "UTF-8" + And the type is "object" + And that "step_position" is set to "" + + Examples: + + | test_description | step_uid | step_position | + | Position-dynaform1 | 8257746325322026c0e45e3047837732 | 1 | + | Position-input2 | 5384383215322090e71aef1047228013 | 2 | + | Position-dynaform2 | 30547852753220293960227013371359 | 3 | + | Position-dynaform4 | 663853222532202eec8a913042063689 | 4 | + | Position-input1 | 853418037532209018ab711041079957 | 5 | + | Position-dynaform3 | 840380819532202d132fb91020992676 | 6 | \ No newline at end of file