I had to downgrade the chai version to 4.2.0 by changing it on the package.json file and running an npm install. Soo it would run with the import you use in the video.
Hi there! Thanks for sharing your experience. It's great to hear that you found a solution by downgrading the chai version to 4.2.0. This is indeed one way to resolve compatibility issues with certain imports. For anyone else encountering similar issues, this approach can help maintain compatibility with the code shown in the video. If you have any more questions or need further assistance, feel free to ask. Happy coding!
Thanks a lot for this. I like how you go slowly explain stuff in details. I am a beginner that really want to learn test automation. Keep up the good work.
Thanks so much for these videos! They have helped me understand these tools and their ability to test far more than before. Thanks again, Ryan! Please do some automation videos for electron and selenium. :D
Your vids are a lifesaver! Thank you! What should I type if I'm going to use just assert style? var assert = require("chai"); -> this doesn't feel right, since assert variable was already created?
Hey Bellatrix 👋🏻 Thank you for liking our videos ❤️ If you want to use just the assert style with Chai, you can use var assert = require("chai").assert; This will import only the assert style from the Chai library and assign it to the assert variable. You can then use the assert variable to write your assertions in your test code.
@@LambdaTest wait, but line higher there is constant variable called assert, so I shouldn't be able to overwrite it with new code. Or with chai I don't need built-in assert?
let todoText= await driver.findElement(By.xpath("//li[last()]")).getText().then(function(value){ return value }); how do this code works and not give you assertion error????
I had to downgrade the chai version to 4.2.0 by changing it on the package.json file and running an npm install. Soo it would run with the import you use in the video.
Hi there! Thanks for sharing your experience. It's great to hear that you found a solution by downgrading the chai version to 4.2.0. This is indeed one way to resolve compatibility issues with certain imports.
For anyone else encountering similar issues, this approach can help maintain compatibility with the code shown in the video. If you have any more questions or need further assistance, feel free to ask. Happy coding!
This worked perfectly, thank you!
Thanks a lot! Ryan is one of the best teacher of this topic:)
Thanks Marina
Thanks a lot for this. I like how you go slowly explain stuff in details. I am a beginner that really want to learn test automation. Keep up the good work.
Thanks udo for your kind words
Thanks for the video
Glad you liked it!
Oh dude, I love you :D
Thanks!
🧘🏻♂️✨
Thank you so much
I'm glad you enjoyed the video!
Subscribe to our channel to never miss an update on the upcoming tutorials! ✨
Thanks so much for these videos! They have helped me understand these tools and their ability to test far more than before. Thanks again, Ryan! Please do some automation videos for electron and selenium. :D
Glad it was helpful!
Your vids are a lifesaver! Thank you!
What should I type if I'm going to use just assert style?
var assert = require("chai"); -> this doesn't feel right, since assert variable was already created?
Hey Bellatrix 👋🏻
Thank you for liking our videos ❤️
If you want to use just the assert style with Chai, you can use
var assert = require("chai").assert;
This will import only the assert style from the Chai library and assign it to the assert variable. You can then use the assert variable to write your assertions in your test code.
@@LambdaTest wait, but line higher there is constant variable called assert, so I shouldn't be able to overwrite it with new code. Or with chai I don't need built-in assert?
Aaah, just watched my answer in the next video! You were reading my mind a year ahead! 😂 Thank you again!
Thank alot
let todoText= await driver.findElement(By.xpath("//li[last()]")).getText().then(function(value){
return value
});
how do this code works and not give you assertion error????
Hey Ali, Let us get back to you on this.
I dont think this is a valid xpath.
Why would this give you an assertion error? Can you share the actual error?
Ali, This Code snippet only reads the text from the web page and returns it as a variable. There is no assertion added here.