Class GetExpected

java.lang.Object
net.bugreaper.modules.mocks.enchanted.EnchantedSetup
net.bugreaper.modules.mocks.enchanted.GetExpected

public class GetExpected extends EnchantedSetup
  • Constructor Details

    • GetExpected

      public GetExpected()
  • Method Details

    • grabExpectedCount

      public static Map<String,String> grabExpectedCount(org.json.JSONObject expectedMockJson)
    • getExpectedBodyType

      public static Map<String,String> getExpectedBodyType(org.json.JSONObject expectedMockSetup)
      Parameters:
      expectedMockSetup - mockVerify JSON
      Returns:
      Map(String, String) example {"json": "json"}, {"rawBody": "body"}, {"jsonSchema": "JSONSchema"} (key can be: rawBody/json/absent/jsonSchema) (value body or same as key or in other case - used for grab from JSON in next steps)
    • getExpectedBody

      public static String getExpectedBody(org.json.JSONObject expectedMockSetup, String bodyType, String bodyNotSensitiveType)
      Parameters:
      expectedMockSetup - JSONObject with mockVerify
      bodyType - type of body for logic from getExpectedBodyType(JSONObject)
      bodyNotSensitiveType - type of body for grab from getExpectedBodyType(JSONObject)
      Returns:
      String with Expected body
    • getExpectedHeaders

      public static String getExpectedHeaders(org.json.JSONObject expectedMockSetup)
    • getExpectedQueryParams

      public static String getExpectedQueryParams(org.json.JSONObject expectedMockSetup)
    • getExpectedStrict

      public static boolean getExpectedStrict(org.json.JSONObject expectedMockSetup, String bodyType, String bodyNotSensitiveType)
    • getExpectedMethodAndPath

      public static String getExpectedMethodAndPath(org.json.JSONObject expectedMockSetup)
    • assertRequestsCountText

      public static String assertRequestsCountText(org.json.JSONObject verifyJSON)