Skip to content

Charter 9: Explore Summary In Situ API with creative parameters and headers to discover surprises

mwalker-scottlogic edited this page Jun 25, 2024 · 4 revisions

Charter:

  • Explore Summary In Situ API with creative parameters and headers to discover surprises

Testers:

  • Mike Walker-Rose

Date:

Duration:

  • 45 - 90 mins

Scope:

  • Assessing response of the API to different headers and parameters

References:

  • Postman
  • MongoDB

Test Approach:

  • Seed the QA database with expected data
  • Using Postman and different test heuristics for inputs, try to generate unexpected results
  • Observe if response error is clear and helpful

Notes

  • measurement_base_time
    • empty - "type": "datetime_from_date_parsing", "loc": [ "query", "measurement_base_time" ], "msg": "Input should be a valid datetime or date, input is too short", "input": "", "ctx": { "error": "input is too short"
    • date format
      • / "msg": "Input should be a valid datetime or date, invalid date separator, expected -", 422
      • . "msg": "Input should be a valid datetime or date, invalid date separator, expected -", 422
      • 20-07-2024T14%3A00%3A00.000%2B00%3A00 (/,.) "msg": "Input should be a valid datetime or date, invalid character in year",422
      • 2024/07/20T14%2A00%3A00.000%2B00%3A00 "msg": "Input should be a valid datetime or date, invalid date separator, expected -", 422
    • number - returns empty array, 200
    • negative number - returns empty array, 200
    • whitespace - "msg": "Input should be a valid datetime or date, input is too short" / "Input should be a valid datetime or date, invalid character in year" 422
    • long paragraph -"msg": "Input should be a valid datetime or date, invalid character in year", 422
    • <>, "msg": "Input should be a valid datetime or date, input is too short", 422
    • leading spaces - "msg": "Input should be a valid datetime or date, invalid character in year", 422
    • trailing space - "msg": "Input should be a valid datetime or date, unexpected extra characters at the end of the input", 422
    • middle space - "msg": "Input should be a valid datetime or date, unexpected extra characters at the end of the input", 422
  • measurement_time_range
    • missing - "msg": "Field required", 422
    • empty - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
    • strings - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
    • numbers - status 200.
      • 1,000 - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
      • 1.0 status 200
      • 1.5 "msg": "Input should be a valid integer, unable to parse string as an integer", 422
      • mathematical operations 422
    • / - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
    • whitespace - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
    • leading spaces - 200
    • trailing space - 200
    • long paragraph - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
    • <> - "msg": "Input should be a valid integer, unable to parse string as an integer", 422
  • location_type
    • missing - "msg": "Field required", 422
    • 1 - "msg": "Input should be 'city'", 422
    • Capitalization - "msg": "Input should be 'city'", 422
    • /*.$% - "msg": "Input should be 'city'", 422
    • empty - "msg": "Input should be 'city'", 422
    • negative number - "msg": "Input should be 'city'", 422
    • whitespace - "msg": "Input should be 'city'", 422
    • leading spaces - "msg": "Input should be 'city'", 422
    • trailing spaces - "msg": "Input should be 'city'",, 422
    • long paragraph - "msg": "Input should be 'city'", 422
    • <>, "msg": "Input should be 'city'",

Conclusion

  • if 'location_type` is a long paragraph, "msg": "Input should be 'city'". If always needs to be city, why have it as a param if it is always the same and required
  • measurement_time_range:
    • can be negative
    • decimal problem 1.0 is 200OK vs 1.5 is a 422
    • whitespace permitted (e.g.' 1' works)
  • you can send a body with the API call e.g {"foo": "bar"}

vAirify Wiki

Home

Getting Started and Overview

Investigations and Notebooks

Testing

Manual Test Charters

Clone this wiki locally