Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,209,186 members, 8,005,221 topics. Date: Sunday, 17 November 2024 at 05:35 PM |
Nairaland Forum / Science/Technology / Programming / Please Who Can Help Me Debug This Testing Code? (343 Views)
Someone, Please Help Debug This Code / Can Somebody Help Me Debug This? / Debug This Code At Your Spare Time. (2) (3) (4)
Please Who Can Help Me Debug This Testing Code? by DDayve: 6:58pm On Oct 05, 2021 |
I am a learner following coding along with an Udemy tutorial. Presently, i am in the section where i am learning testing. This exact code, my instructor ran it and it worked but mine didn't work, i have carefully observed my code and compared to his, no difference. i have also applied my little knowledge to see where i am missing it, yet no solution. please i need somebody to rescue me. the image of the codes are attached below 1. The first image is the script file 2. The second image is the first test testing the async await function. the test was successful 3. The 3rd image is the second test testing the promise function. The test wasn't successful and i expect it to be. They are suppose to be the same
|
Re: Please Who Can Help Me Debug This Testing Code? by angelEmade: 7:04pm On Oct 05, 2021 |
Are you sure this is not a library or compiler issue? Are you using the exact same compiler your instructor used? |
Re: Please Who Can Help Me Debug This Testing Code? by DDayve: 7:12pm On Oct 05, 2021 |
angelEmade: Node of the codes worked at first, i had to uninstall the latest node-fetch which I installed to install the exact one my instructor used. There are two main packages my instructor used. 1. Jest and 2. node-fetch. Since you have given me the opinion, i will have to downgrade the second package oo. Thanks boss, lemme try it. I am just wondering if async await and promises will work differently on different compilers |
Re: Please Who Can Help Me Debug This Testing Code? by angelEmade: 8:34pm On Oct 05, 2021 |
DDayve:Well m more into php and native JAVA While o can't exactly pin point a problem (assuming there is any) it is something I have learned over the years from my general knowledge of software development. In most cases compiler libraries and packages are the problem. If the code has an issue, m pretty sure your ide should throw an error especially if you are using one of these IDEs that's designed specifically for that programming lang. |
Re: Please Who Can Help Me Debug This Testing Code? by DDayve: 8:42pm On Oct 05, 2021 |
angelEmade: Noted boss. Thanks. I will just assume async await is preferable for testing and move on. I have tried downgrading the second package but so many functionalities has been deprecated. As such, it didn't work. In fact, it was worst |
(1) (Reply)
URGENT: In Need Of An R Language Expert / Please, Recommend A Programming Laptop With Excellent Battery Performance. / The Leading Ict Center In Abia State
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 17 |