From 282abcdfc6cc2cec0ad8c2c0bca67e260283f9a4 Mon Sep 17 00:00:00 2001 From: Prateek Surana Date: Mon, 26 Feb 2024 11:47:52 +0530 Subject: [PATCH] Add comments wherever necessary --- .../java/io/supertokens/test/CoreConfigListAPITest.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/test/java/io/supertokens/test/CoreConfigListAPITest.java b/src/test/java/io/supertokens/test/CoreConfigListAPITest.java index 7d6fc638e..a17bd5047 100644 --- a/src/test/java/io/supertokens/test/CoreConfigListAPITest.java +++ b/src/test/java/io/supertokens/test/CoreConfigListAPITest.java @@ -108,6 +108,8 @@ public void testProtectedConfigsAreHandledCorrectlyIfSuperTokensSaaSSecretIsSet( String[] protectedPluginFields = StorageLayer.getBaseStorage(process.main) .getProtectedConfigsFromSuperTokensSaaSUsers(); + // Make sure that the protected fields are not included in the response + // if supertokens_saas_secret is set and it is not used for api_key { JsonObject response = HttpRequestForTesting.sendJsonRequest(process.getProcess(), "", "http://localhost:3567/core-config/list", @@ -127,6 +129,8 @@ public void testProtectedConfigsAreHandledCorrectlyIfSuperTokensSaaSSecretIsSet( } } + // Make sure that the protected fields are included in the response + // if supertokens_saas_secret is set and it is used for the api_key { JsonObject response = HttpRequestForTesting.sendJsonRequest(process.getProcess(), "", "http://localhost:3567/core-config/list", @@ -149,7 +153,7 @@ public void testProtectedConfigsAreHandledCorrectlyIfSuperTokensSaaSSecretIsSet( } if (allProtectedFields.size() > 0) { - fail("Protected configs " + allProtectedFields + " are not included in the response even though supertokens_saas_secret is added in the request."); + fail("Protected configs " + allProtectedFields.toString() + " are not included in the response even though supertokens_saas_secret is added in the request."); } }