Part 5 - Docker Commands
49:19
4 ай бұрын
Пікірлер
@RaghavendraKarteek
@RaghavendraKarteek 12 күн бұрын
Nice video. please Post more videos related unit testing using Angular 17 or latest versions . please cover NGRX and RXJS unit test cases as well
@kyprogramming
@kyprogramming 12 күн бұрын
@@RaghavendraKarteekThank you Raghav for your support. Certainly I will cover those topics.
@RaghavendraKarteek
@RaghavendraKarteek 12 күн бұрын
@@kyprogramming Thanks..
@rahulmehta0852
@rahulmehta0852 Ай бұрын
thx
@kyprogramming
@kyprogramming Ай бұрын
Your welcome
@AmolAute-n1j
@AmolAute-n1j Ай бұрын
Thanks
@uzomanwanne2751
@uzomanwanne2751 Ай бұрын
Very nice lectures. I noticed your GitHub link is broken.
@rahulmehta0852
@rahulmehta0852 Ай бұрын
nice video sir ji
@kyprogramming
@kyprogramming Ай бұрын
@@rahulmehta0852 Thank you Rahul!
@MithileshPandey-gb4xw
@MithileshPandey-gb4xw Ай бұрын
good example....where can i get the code for this?
@SagarSharma-t8y
@SagarSharma-t8y Ай бұрын
today i completed , as of now i got a good idea about chai and mocha
@kyprogramming
@kyprogramming Ай бұрын
@@SagarSharma-t8y thank you for following this.
@satishchandra3076
@satishchandra3076 2 ай бұрын
Connecting Database from angular app, pls make a video
@kyprogramming
@kyprogramming 2 ай бұрын
@@satishchandra3076 Dear Satish, angular does not connect directly with database. It connect with the database using API. Certainly I'll make the video on it. Thank you for your suggestion.
@amitchauhan1505
@amitchauhan1505 2 ай бұрын
very confusing way to explain. All cluttered.
@kyprogramming
@kyprogramming 2 ай бұрын
Hi Amil, what is you confusion ? Would you please explain a bit more. I would try to solve your query. Thanks
@jyotiagre4430
@jyotiagre4430 2 ай бұрын
how import calculator can you please help me?
@kyprogramming
@kyprogramming 2 ай бұрын
Hi Jyoti,this is just an example taken as Calculator class but you can you use your class in your project in a similar way of writing test cases.
@kyprogramming
@kyprogramming 2 ай бұрын
Further you can use to import class like below code import Calculator from 'abs path for your file'; in case of default export
@jyotiagre4430
@jyotiagre4430 2 ай бұрын
Exception during run: TypeError: Unknown file extension ".ts",how solve this error
@kyprogramming
@kyprogramming 2 ай бұрын
Hi, Would you please install Chai later version "chai":"^4.3.7" to see if this solve your issue
@jyotiagre4430
@jyotiagre4430 2 ай бұрын
How install
@kyprogramming
@kyprogramming 2 ай бұрын
First of all remove existing Chai from your package.json file and then run npm i chai
@jyotiagre4430
@jyotiagre4430 2 ай бұрын
Thank you
@jyotiagre4430
@jyotiagre4430 2 ай бұрын
What is next command
@Wh---
@Wh--- 2 ай бұрын
Do you have js notes , Share Sir
@kyprogramming
@kyprogramming Ай бұрын
Thank you. Code should be there in the GitHub link provided in the description. Please let me know if you don't find it.
@kaushikraj521
@kaushikraj521 3 ай бұрын
Exception during run: TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" plz solve this error
@kyprogramming
@kyprogramming 3 ай бұрын
Certainly I would help you on this. Could you please share yr package.json and tsconfig.json file to me.
@forprogrammers6827
@forprogrammers6827 3 ай бұрын
very good explanation.
@kyprogramming
@kyprogramming 3 ай бұрын
Thank you 👍
@cesrra_
@cesrra_ 3 ай бұрын
To solve the "TypeError [ERR_UNKNOWN_FILE_EXTENSION]" Install the version "^4.3.7" of chai
@orlandopl267
@orlandopl267 2 ай бұрын
I solved the error installing that mentioned version of chai but why did it work?
@kyprogramming
@kyprogramming 2 ай бұрын
@orlandopl267 good to know that you have solved issue by installing later version of Chai. Really not sure what could be reason behind it. However there was issue raised for this in Chai. Please see below link for for details. github.com/chaijs/issues/1568
@JaroslawKubiak-hq8qd
@JaroslawKubiak-hq8qd 3 ай бұрын
Did you have to put this Subscription notification every minute?
@kyprogramming
@kyprogramming 3 ай бұрын
Thanks for your suggestion, I have moved subscription notification in the last for all my later uploaded videos.
@TheDekhun
@TheDekhun 3 ай бұрын
Great Tutorial. Thanks for the content
@kyprogramming
@kyprogramming 3 ай бұрын
Thank you👍
@priscachidimma1896
@priscachidimma1896 3 ай бұрын
You explained very clearly 👏
@kyprogramming
@kyprogramming 3 ай бұрын
Thank you Prisca!!
@shr3y4sh
@shr3y4sh 4 ай бұрын
Mast kaam krta hi bhai tum
@kyprogramming
@kyprogramming 4 ай бұрын
Thank you Shreyash for comment!
@styfleur880
@styfleur880 4 ай бұрын
Thank you for the content. I have a question. How do you mock, stub or spy an anonym function?
@kyprogramming
@kyprogramming 4 ай бұрын
Thank you for your comment. Its a very good question , so I thought to make a video on this, which I have published it today. I hope this will be helpful to understand. Please let me know if you have if still you have any query. Link is given mentioned below: kzbin.info/www/bejne/qHqmXn2JaZKXrLc
@adelminwer2675
@adelminwer2675 5 ай бұрын
amazing content bro
@kyprogramming
@kyprogramming 5 ай бұрын
Thank you Adelminwer 👍
@Zainab-kazme
@Zainab-kazme 5 ай бұрын
Thanks much 👍🏻
@kyprogramming
@kyprogramming 5 ай бұрын
Thank you Zainab👍
@sourabhkumar3333
@sourabhkumar3333 5 ай бұрын
kzbin.info/www/bejne/fHmwloWArLyLgJY both are same or diffrent??
@kyprogramming
@kyprogramming 5 ай бұрын
this is one part of the complete video. thank for checking.
@butenitin
@butenitin 5 ай бұрын
very simple and best explanation.
@kyprogramming
@kyprogramming 5 ай бұрын
Thank you for your comment !!
@KarthickRajendran-y2v
@KarthickRajendran-y2v 5 ай бұрын
Thank bro. Very well explained
@kyprogramming
@kyprogramming 5 ай бұрын
Thanks a lot for your comment 👍
@HemanthC-we3wb
@HemanthC-we3wb 5 ай бұрын
Hi bro, i tried all the methods to solve but still i am facing the issue "hemanthc@Hemanths-MacBook-Air API-testing-pratice % npm run test > [email protected] test > mocha --require ts-node/register test/**.spec.ts Exception during run: TypeError: Unknown file extension ".ts" for /Users/hemanthc/API-testing-pratice/test/calculator.spec.ts at Object.getFileProtocolModuleFormat [as file:] (node:internal/modules/esm/get_format:160:9) at defaultGetFormat (node:internal/modules/esm/get_format:203:36) at defaultLoad (node:internal/modules/esm/load:143:22) at async ModuleLoader.load (node:internal/modules/esm/loader:409:7) at async ModuleLoader.moduleProvider (node:internal/modules/esm/loader:291:45) at async link (node:internal/modules/esm/module_job:76:21) { code: 'ERR_UNKNOWN_FILE_EXTENSION' }Z " can u help me
@kyprogramming
@kyprogramming 5 ай бұрын
Certainly I would like to help.. Please let me know if we could connect on FB.
@shoxruxnurmuxammedov7181
@shoxruxnurmuxammedov7181 5 ай бұрын
thank you sir, it was very helpful
@kyprogramming
@kyprogramming 5 ай бұрын
Thank you for your valuable comment ! 👍
@shoxruxnurmuxammedov7181
@shoxruxnurmuxammedov7181 5 ай бұрын
good job!, that's exactly what I was looking for
@kyprogramming
@kyprogramming 5 ай бұрын
Glad I could help!
@manojhk7469
@manojhk7469 5 ай бұрын
usefull and in depth explanation.
@kyprogramming
@kyprogramming 5 ай бұрын
Thank you Manoj!
@PreCodeCamp
@PreCodeCamp 5 ай бұрын
Useful tips thanks for sharing. Scope and hoisting are always hard concepts to understand. You went nice and slow.
@universal4334
@universal4334 6 ай бұрын
Hi bro. Need you gmail id
@viral_topics_memes
@viral_topics_memes 6 ай бұрын
nice but thoda zoom karo
@kyprogramming
@kyprogramming 6 ай бұрын
Thank you!!
@sammiewilkinson4079
@sammiewilkinson4079 6 ай бұрын
😔 'Promo sm'
@leemanheilee88
@leemanheilee88 6 ай бұрын
The bell ring is so annoying
@kyprogramming
@kyprogramming 6 ай бұрын
Thank you for letting me know.. I will take care of bell ring from all my upcoming video.
@ShahrukhWonder
@ShahrukhWonder 6 ай бұрын
Best vdo on int
@kyprogramming
@kyprogramming 6 ай бұрын
Thank you Shahrukh for your comment!
@aparnamishra1530
@aparnamishra1530 7 ай бұрын
very informative video, i have a question, what if i use toPromise() with observables instead of promise? You can make a separate video on it. also explain await, async in the same video so that we'll get clear idea.
@kyprogramming
@kyprogramming 7 ай бұрын
Thank you Aparna! .toPromise is utility method from Observable and that is used to convert an Observable into a Promise which resolve promise with the last emited value. Hope I have answered for your query. Certainly I will make an video on async and await soon. Thank you for your suggestion. Thanks
@aparnamishra1530
@aparnamishra1530 7 ай бұрын
thank u@@kyprogramming
@akiii461
@akiii461 7 ай бұрын
thanks for the detailed comparison....
@kyprogramming
@kyprogramming 7 ай бұрын
Your welcome👍
@mustafasdet5446
@mustafasdet5446 7 ай бұрын
Hi. Executed same actions with you but getting "TypeError: Unknown file extension ".ts" for ...path/calculator.spec.ts i have searched the error in google but recommended solutions causing other errors. Do you have any suggestion? Thx
@kyprogramming
@kyprogramming 7 ай бұрын
If you're encountering an "unknown file extension .ts" error while using Mocha, it likely means Mocha doesn't recognize TypeScript files by default. To fix this, you can use a tool like ts-node to transpile TypeScript files on-the-fly before running tests. npm install --save-dev ts-node tsconfig-paths Also could please add .mocharc.json file.. { "extensions": ["ts"], "spec": ["**/*.spec.*"], "node-option":[ "experimental-specifier-resolution=node", "loader=ts-node/esm" ] } This could solve your problem. Please let me know if this solve your issue. Thanks
@adanos2006
@adanos2006 2 күн бұрын
try to use chai version 4.5.0. i had same problem and it's helps
@hemachandran8082
@hemachandran8082 7 ай бұрын
How is const a is accessible inside function second as its block scope?
@kyprogramming
@kyprogramming 7 ай бұрын
Thank you Hema for your query.. Variable a is declared in global scope and it will be lexically scoped to all the child scope, therefore it's been accessible inside the block scope. I hope I have answered for your query.. Thanks
@bgovindnaren7405
@bgovindnaren7405 7 ай бұрын
One genuine doubt of mine... Isn't this same as saying a =0 b =0 and hence a =b? no offence fantastic video!
@kyprogramming
@kyprogramming 7 ай бұрын
Thank you Govind for your comment! If you are saying a=b it means you are assigning value of b to a. In order to check equality for a & b you should use == or === strict equality check operator like a === b or a == b. I hope I have answered for you query. Thanks.
@bgovindnaren7405
@bgovindnaren7405 7 ай бұрын
@@kyprogramming No sir... In the test we are only setting the value for the mocked response(let say for the response status is always gonna be 200 because we have returned the same in the main file) and in the expect(res.status) we saying that it should be equal to 200 So its always gonna pass the testcase if you only change the status from 200 to 404 in the expect statement then only it will fail. So in this analogy isn't this same as that of saying let a = 0. and b = 0( 0 is nothing but mocked response and the expected response in the expect statement) and saying a = b. In that sense I was asking the question. Pls clarify this doubt of mine.
@kyprogramming
@kyprogramming 7 ай бұрын
​@@bgovindnaren7405 ok, got your point. whenever we are trying to test any functions , we should mock other dependencies with the some mocked response (should not necesary have the actulal response )and same can we verify under assert. The whole idea is to test functionality for the relevent function under a single test cases not to the it's dependencies. Also its depends upon requirements and use cases what exactly we have to test. In this tutorial I have explained how we can utilize nock libraby in order to mock our actual API functionality for GET and POST. Hope I make it clear to you.
@jaywantnarwade5517
@jaywantnarwade5517 7 ай бұрын
where is interview questions and answer?
@kyprogramming
@kyprogramming 7 ай бұрын
Hi Jaywant, this is mainly cover difference between difference among unit , integration and e2e testing and how to perform in angular. Please let me know if you are looking for any specific questions?
@suen-tech
@suen-tech 7 ай бұрын
Thank you
@kavinkumar
@kavinkumar 7 ай бұрын
Hi Kumar, how the deep copy is handling the function , whats the type of d key here ?
@kyprogramming
@kyprogramming 7 ай бұрын
Hi Kavin , thank you for your comment.. JavaScript doesn't have a function data type but when we find the data type of a function using the typeof operator, we find that it returns a function. This is because a function is an object in JavaScript. Ideally the data type of a function should return an object but instead, it returns a function. I hope, I have answered for your query.
@ashishkushwaha8773
@ashishkushwaha8773 7 ай бұрын
very well explained. keep it up
@kyprogramming
@kyprogramming 7 ай бұрын
Thank you Ashish for your comment. 👍
@ashishkushwaha8773
@ashishkushwaha8773 7 ай бұрын
great content
@kyprogramming
@kyprogramming 7 ай бұрын
Thank you Ashish for your comment!
@prasantakumarroutray2105
@prasantakumarroutray2105 8 ай бұрын
how excellent ur teaching style....super se upper
@kyprogramming
@kyprogramming 8 ай бұрын
Thank you Prasanta!
@48_ritusharma46
@48_ritusharma46 8 ай бұрын
Well explained sir
@shwetabhat9981
@shwetabhat9981 8 ай бұрын
Great content sir . Thank you for the efforts . Keep growing 🎉
@kyprogramming
@kyprogramming 8 ай бұрын
Thank you Sweta for your appreciation and liking my contents.
@xaini-137
@xaini-137 8 ай бұрын
after esm:true :getting error TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" for /Users/xainis/Documents/typescript/typePost/src/index.ts
@kyprogramming
@kyprogramming 8 ай бұрын
Please install ts-node npm install -g ts-node And also remove type:module from package.json It should be working as expected. Please let me know if still you are facing issue..
@xaini-137
@xaini-137 8 ай бұрын
@@kyprogramming already installed nodemon and ts-node
@kyprogramming
@kyprogramming 8 ай бұрын
@@xaini-137 ok please let me know what time will be suitable for you, will setup a Google meet and certainly help you on this. Definitely there is some small configuration would be missing.. Also please let me know which nodejs version are you using?
@xaini-137
@xaini-137 8 ай бұрын
v20.10.0@@kyprogramming
@kyprogramming
@kyprogramming 8 ай бұрын
@@xaini-137 v20 should be good. Please contact me on telegram t.me/+lZMiJxI4GeNjY2Vl Will setup a meeting to resolve you issues free of cost.
@yanntrad2304
@yanntrad2304 8 ай бұрын
Hi thanks for this video but when npm run test got the error TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts"
@kyprogramming
@kyprogramming 8 ай бұрын
Hi Yann, have you installed ts-node? and please go step by step all the installation process. Still you are having any issue please connect me on facebook chat, certainly will help you on this.
@Antonym-b5o
@Antonym-b5o 8 ай бұрын
the same add file .mocharc.json { "extensions": ["ts"], "spec": ["**/*.spec.*"], "node-option": [ "experimental-specifier-resolution=node", "loader=ts-node/esm" ] }
@kyprogramming
@kyprogramming 8 ай бұрын
Could you please try to run following command : npm i tsc -g npm i typescript -g npm i ts-node -g And also ensure you have configuration in tsconfig.json file as "module": "commonjs" This should solve your problem. Please let me know if still you are facing this issue. Thanks
@Antonym-b5o
@Antonym-b5o 8 ай бұрын
I can't use commonjs. The project has modules. Anyway the my way is works
@kyprogramming
@kyprogramming 8 ай бұрын
@@Antonym-b5o great stuff! glad to hear your issue is resolved.