4 Test not passing in Quality Assurance Projects - Metric-Imperial Converter

My code seems to be working, executing fine, and when I console.log the values concerning the 4 test I’m not passing, it is logging the correct values.
But, my code is not passing 4 test:
“invalid number”,
“invalid unit”,
“invalid number and unit”,
“initNum initUnit converts to returnNum returnUnit”

Here’s the link to my repl.it: https://boilerplate-project-metricimpconverter-1.nwbraycode.repl.co

Here’s the link to the test page: Quality Assurance Projects - Metric-Imperial Converter | Learn | freeCodeCamp.org

did you check there type properly, you need to convert numbers stored as string into integers or float

Thank you for responding kashimi.
The problem isn’t the convert numbers. The problem is…
For the tests,
examples of the above:

  • if there is a double forward slash “//” it’s suppose to return “invalid number”,
  • if the unit is “lbs, kg, km, mi, l, gal” or their uppercase versions, then “invalid input” is suppose to be returned,
  • if the number and unit is invalid, then “invalid number and unit is suppose to be returned”

Answer:
If in app.js you use "if " statements to check if “invalid number”, “invalid unit”, or “invalid number” and “invalid unit” are returned by the variables “initNum” and “initUnit” and use res.json("invalid number"), res.json("invalid unit"), res.json("invalid number and unit") before res.json({initNum, initUnit, init_Units, returnNum, returnUnit, return_Unit, string: toString }) make sure in the functional test with respects to each one of those res.json()s you test only for that string within it… for example: for “invalid number and unit” in ‘Convert 3/7.2/4kilomegagram (invalid number and unit)’ test, test for assert.equal(req.body, "invalid number and unit") and not for req.body.initNum and req.body.initUnit because they wont be there since the res.json is only sending the string “invalid number and unit”.

for my other problem: “initNum initUnit converts to returnNum returnUnit”,

I was plugging in the wrong variables. “initUnit” should have been “init_Units” and “returnUnit” should have been “return_Unit”:

let toString = convertHandler.getString(initNum, init_Units, returnNum, return_Units);

and test for that with assert.equal(input/actual-value, expected-value) ;

Keep smiling.

Kindly provide your code work please, because I am facing some issues to pass the test, please help me out
My glitch link: https://glitch.com/edit/#!/measuremental