diff --git a/test/hurl/api/contracts/10_contracts.hurl b/test/hurl/api/contracts/10_contracts.hurl index fc5f6850ade..b33d072b68c 100644 --- a/test/hurl/api/contracts/10_contracts.hurl +++ b/test/hurl/api/contracts/10_contracts.hurl @@ -100,11 +100,12 @@ HTTP 200 # GET contracts DOLAPIENTITY: 2 GET http://{{hostnport}}/api/index.php/contracts DOLAPIENTITY: 2 -HTTP 403 +HTTP 401 [Asserts] jsonpath "$.error" exists -jsonpath "$.error.code" == 403 -jsonpath "$.error.message" == "Forbidden" +jsonpath "$.error.code" == 401 +jsonpath "$.error.message" contains "Unauthorized" +jsonpath "$.error.message" contains "Token not valid (may be a typo or a wrong entity)" # http://localhost:8080/api/index.php/contracts?sortfield=t.rowid&sortorder=ASC&limit=1 diff --git a/test/hurl/api/emailtemplates/10_emailtemplates.hurl b/test/hurl/api/emailtemplates/10_emailtemplates.hurl index 95531c278e5..7efcbbcbbe7 100644 --- a/test/hurl/api/emailtemplates/10_emailtemplates.hurl +++ b/test/hurl/api/emailtemplates/10_emailtemplates.hurl @@ -100,11 +100,12 @@ HTTP 200 # GET emailtemplates DOLAPIENTITY: 2 GET http://{{hostnport}}/api/index.php/emailtemplates DOLAPIENTITY: 2 -HTTP 403 +HTTP 401 [Asserts] jsonpath "$.error" exists -jsonpath "$.error.code" == 403 -jsonpath "$.error.message" == "Forbidden: denied access to email templates" +jsonpath "$.error.code" == 401 +jsonpath "$.error.message" contains "Unauthorized" +jsonpath "$.error.message" contains "Token not valid (may be a typo or a wrong entity)" # GET id of first element GET http://{{hostnport}}/api/index.php/emailtemplates?limit=1&page=0 diff --git a/test/hurl/api/users/10_groups.hurl b/test/hurl/api/users/10_groups.hurl index 24d9743529e..937b7085640 100644 --- a/test/hurl/api/users/10_groups.hurl +++ b/test/hurl/api/users/10_groups.hurl @@ -67,4 +67,8 @@ HTTP 200 GET http://{{hostnport}}/api/index.php/users/groups DOLAPIENTITY: 2 HTTP 401 -{"error":{"code":401,"message":"Unauthorized: Error user not valid (not found with api key or bad status or bad validity dates) (conf->entity=2)"}} +[Asserts] +jsonpath "$.error" exists +jsonpath "$.error.code" == 401 +jsonpath "$.error.message" contains "Unauthorized" +jsonpath "$.error.message" contains "Token not valid (may be a typo or a wrong entity)" diff --git a/test/hurl/api/users/10_users.hurl b/test/hurl/api/users/10_users.hurl index fd9a5049c09..31b1543387b 100644 --- a/test/hurl/api/users/10_users.hurl +++ b/test/hurl/api/users/10_users.hurl @@ -76,4 +76,8 @@ HTTP 200 GET http://{{hostnport}}/api/index.php/users DOLAPIENTITY: 2 HTTP 401 -{"error":{"code":401,"message":"Unauthorized: Error user not valid (not found with api key or bad status or bad validity dates) (conf->entity=2)"}} +[Asserts] +jsonpath "$.error" exists +jsonpath "$.error.code" == 401 +jsonpath "$.error.message" contains "Unauthorized" +jsonpath "$.error.message" contains "Token not valid (may be a typo or a wrong entity)" \ No newline at end of file diff --git a/test/hurl/api/warehouses/10_warehouses.hurl b/test/hurl/api/warehouses/10_warehouses.hurl index 9e28ae9699a..2a22193fee0 100644 --- a/test/hurl/api/warehouses/10_warehouses.hurl +++ b/test/hurl/api/warehouses/10_warehouses.hurl @@ -106,8 +106,12 @@ HTTP 200 # GET warehouses DOLAPIENTITY: 2 GET http://{{hostnport}}/api/index.php/warehouses DOLAPIENTITY: 2 -HTTP 403 -{"error":{"code":403,"message":"Forbidden"}} +HTTP 401 +[Asserts] +jsonpath "$.error" exists +jsonpath "$.error.code" == 401 +jsonpath "$.error.message" contains "Unauthorized" +jsonpath "$.error.message" contains "Token not valid (may be a typo or a wrong entity)" # http://localhost:8080/api/index.php/warehouses?sortfield=t.rowid&sortorder=ASC&limit=1 diff --git a/test/hurl/gui/admin/10_mails_templates.hurl b/test/hurl/gui/admin/10_mails_templates.hurl index d24ba9e349d..8c02443d2ba 100644 --- a/test/hurl/gui/admin/10_mails_templates.hurl +++ b/test/hurl/gui/admin/10_mails_templates.hurl @@ -12,7 +12,6 @@ body contains "Language" body contains "Module/Application" body contains "Owner" body contains "Position" -body contains "Private" body contains "Status" body contains "Subject" body contains "Type of template"