How To Find Broken Links Using Selenium With Java

  Рет қаралды 83,367

Mukesh otwani

Mukesh otwani

Күн бұрын

Пікірлер: 155
@kittu245
@kittu245 8 жыл бұрын
Hiii Mukesh This is Siva from USA your videos are just awesome ,very easy to understand for any one and really you are doing a great job ,anyone can learn easily from your videos without going to any institute.Please continue this and i would like to suggest you to keep some frequently asked questions in interviews with examples and also explain some real time scenarios Thank u you so much
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Siva rama krishna Ryali Hi Siva that is my next Step.. Keep visiting and thank a ton for nice feedback. Let me know if any help required from my side.
@robingajbhiye1291
@robingajbhiye1291 8 жыл бұрын
Hi Mukesh, I really appreciate you for taking effort to educate us. I follow you channel and website on daily basis It will be really great if you can make videos for Keyword and Hybrid Frameworks with detailed project structure that are followed by companies. Thank you..
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Robin Gajbhiye Hi Robin it is in queue will upload soon.
@pranalikumbhare3547
@pranalikumbhare3547 8 жыл бұрын
Hi Mukesh......Your videos are awesome and very helpful. Which are help me to increase my knowledge and help in teaching. Doing great job ...Thanks......
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Pranali Kumbhare Thank you pranali let me know if any help from my side.
@pranalikumbhare3547
@pranalikumbhare3547 8 жыл бұрын
+Mukesh otwani Ofcourse
@shafaathussain6104
@shafaathussain6104 8 жыл бұрын
Really Nice , You made it simple and easy to understand , Thanks a Lot
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+shafaat hussain Hi Shafft glad to know it helped you .
@RajaRam-AutomationTesting
@RajaRam-AutomationTesting 7 жыл бұрын
Hi, Mukesh thank you so much for your Tutorials. Your tutorials helped me a lot to learn selenium
@prasannakulkarni3350
@prasannakulkarni3350 8 жыл бұрын
superb bro.....i get the concept very clearly seeing your videos
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+prasanna kulkarni Thanks Prasanna
@coco3625
@coco3625 8 жыл бұрын
Mukesh really appreciated !! always like your upload videos, it's help me a lot to started my selenium project. the way you teach is the best to compared to other instructor.
@maxwellonyx9636
@maxwellonyx9636 3 жыл бұрын
dunno if you guys gives a damn but if you guys are bored like me during the covid times then you can watch pretty much all of the latest movies and series on Instaflixxer. Been binge watching with my brother for the last days :)
@sorencarmelo4201
@sorencarmelo4201 3 жыл бұрын
@Maxwell Onyx definitely, I've been using Instaflixxer for months myself =)
@neetugupta8019
@neetugupta8019 6 жыл бұрын
Always like Sir..great effort from your side for us....Thank you very much ...
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
🙏🙏🙏🙏 Thanks Neetu whenever u need any help don't hesitate to contact me
@AbhishekTak5
@AbhishekTak5 4 жыл бұрын
Thank you Mukesh for this!!!perfectly explained !!
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
Glad it was helpful! Abhishek
@fahimkhatri4467
@fahimkhatri4467 8 жыл бұрын
This is so cool !!! super... always worth watching your videos.
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
thanks Fahim keep visiting happy weekend..
@alka240280
@alka240280 5 жыл бұрын
Thank you for the awesome explanation!
@Mukeshotwani
@Mukeshotwani 5 жыл бұрын
Thank you Sharma ji .. Please do watch other videos too and let me know if you have any doubt.
@survivorfighter4683
@survivorfighter4683 5 жыл бұрын
Total Life Saver!! Thank You!
@Mukeshotwani
@Mukeshotwani 5 жыл бұрын
Thank you mate, I am glad to know that my video has helped you.
@sonalipradhan6050
@sonalipradhan6050 7 жыл бұрын
Hi, Mukesh really this broken links video is very helpful. Can you pl suggest how to write assert method for broken links in testNG.
@jeevankale1
@jeevankale1 8 жыл бұрын
Hi Mukesh...One query this count is the only for that particular page ya entire application link count?
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
You can use for single link as well.
@manikantanagudu4967
@manikantanagudu4967 8 жыл бұрын
Hi Mukesh really nice viedo. please post viedo reading How to handle broken images in selenium Webdriver.
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Nagudu Manikanta thanks yes I will upload soon
@manikantanagudu4967
@manikantanagudu4967 8 жыл бұрын
Thankq
@piyush12071990
@piyush12071990 8 жыл бұрын
You are awesome Bro..
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+piyush RAGHATATE Thanks Piyush :) keep visiting other videos as well and let me know if any help from myside.
@saiedtrefi5487
@saiedtrefi5487 8 жыл бұрын
Thanks great video
@SuyashNande
@SuyashNande 7 жыл бұрын
Awesome video. thanks!
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
Thanks Suyash :)
@stanu1159
@stanu1159 6 жыл бұрын
Hi sir u r teaching is awesome..please upload. Video's on java programming
@ioriiori
@ioriiori 4 жыл бұрын
It’s nice , thanks a lot , I have one question, when I run the test , it includes so many same links , duplicated links . How can I remove it ? Please help .
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
You can convert List into Set which will remove duplicate element or items.
@nitingupta82
@nitingupta82 8 жыл бұрын
Superb! Another exciting way to find Terror sorry Error, HTTP Response Code 404!! :)
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Nitin Gupta Thanks Nitin :)
@upendrad6081
@upendrad6081 8 жыл бұрын
Hey Mukesh, I am not sure in which video I needs to ask you. I have a scenario like, I am looping through and getting some element text and storing into an array. But in b/w if the page updating with the latest values, code is going to exception telling that the element not attached to DOM. So here what I want to do is, I don't want to get the page to be refreshed till the loop completes and I don't need latest values also. Please help me on this. Got struck here with it...
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Upendra D is it fixed?
@upendrad6081
@upendrad6081 8 жыл бұрын
Not fixed Mukesh. That would be great if u can give me a way...
@upendrad6081
@upendrad6081 8 жыл бұрын
+Mukesh otwani hi, Mukesh got any way for this please?
@upendrad6081
@upendrad6081 8 жыл бұрын
+Upendra D Hi Mukesh, Sorry to followup again and again. But got struct here. Can you please help me out there...
@deepakjaiswal5516
@deepakjaiswal5516 8 жыл бұрын
hello sir please upload some video for data driven framework from basics to advance...
@dipukakati4
@dipukakati4 7 жыл бұрын
Hi Mukesh - If we use String linkText=ele.getText(); and String linkText=ele.getAttribute("innerText") to find the link text -what will be difference in output
@mahendratiwary3689
@mahendratiwary3689 6 жыл бұрын
Hi Mukesh, How do I convert this code to run for TestNG? I basically want to fail the test case if there is a broken link. I assume this is what is required when you are given to test if all links on a page is working fine. Right?
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hi Mahendra you can use @Test to convert with TestNG kzbin.info/www/bejne/hYXXd4akj75nnJo Yes, I agree we need to put assert when we dont get 200 response code.
@hennymakaveli
@hennymakaveli 8 жыл бұрын
Hello Mukesh, can you make a video/tutorial on broken image link, especially the verification method that you will pass the image argument to?
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
Hi Oludare you can use src attribute for images and follow the same video.
@udaybenake206
@udaybenake206 8 жыл бұрын
Hey mukesh could you explain what is verifyLinkActive() is
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
I just created lib for reusing purpose
@ishanmittal4732
@ishanmittal4732 7 жыл бұрын
Hi Mukesh Thanks for this video!! I tried this code & and its working fine but when there is some urls having "null" or having "javascripts void", how can we skip that part?
@nexonsamuel
@nexonsamuel 8 жыл бұрын
Hello!!!Can you please make a video demonstrating how to work with context clicks and other such right click options???
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Nexon Samuel Hi Nexon sure will make soon. You can visit my blog in meantime for the same.learn-automation.com/selenium-advance-activity/
@nexonsamuel
@nexonsamuel 8 жыл бұрын
+Mukesh otwani Thank You So much!!!!Eagerly waiting
@sachinjaiswal9054
@sachinjaiswal9054 6 жыл бұрын
Hey mukesh! Are u discussing the assignment anywhere. i was trying one of them you gave in this video to have assert condition included in this and was a bit confused
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hey Sachin where is your confusion?
@jgsidenotes
@jgsidenotes 6 жыл бұрын
Hi thank you for this helpful tutorial, but what about if I want to test the whole website links? with multiple pages
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hi Jomari in that case we have to keep calling the method which we created for each and every page.
@sachinjaiswal9054
@sachinjaiswal9054 6 жыл бұрын
I have the program which you discussed and it works. How To convert this into TestNg. I'm asking this basic question as I'm still at learning stage. Kindly guide me.
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hi Sachin, Please follow below document/link for TestNG kzbin.info/www/bejne/hYXXd4akj75nnJo
@sachinjaiswal9054
@sachinjaiswal9054 6 жыл бұрын
My question was you gave a small assignment in this video at 0.38 s of this kzbin.info/www/bejne/hYXXd4akj75nnJo video. This assignment was to convert the program written into TestNG framework by adding an assertion framework. 11.20 sec. was asking that only. How to convert this program into TestNG framework and add assertion
@halabadr2571
@halabadr2571 8 жыл бұрын
Hello Mukesh, how can we print the final result & count of the Active and Broken links ?
@manikandanparthiban4165
@manikandanparthiban4165 7 жыл бұрын
Hi Mukesh. I'm trying to check if a certain image is present in a pdf. Could you recommend any API? Thanks
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
Hi Mani, This will help you read pdf file content org.apache.pdfbox pdfbox 2.0.6
@manikandanparthiban4165
@manikandanparthiban4165 7 жыл бұрын
Thank you Mukesh. I used itext pdf and I was able to do the validation.
@tasneemtechno4014
@tasneemtechno4014 7 жыл бұрын
Hi Mukesh. My website has 156 links in total and this code shows total count of 141. what could be the reason? Also, when i check from console, it shows 120 links with their status but not total identified i.e. 141.
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
Hi Tasneem, Yes I got your point the reason why it is showing 141 is because some links are only JS (Java Script)link which does not have href attribute so above code will only check link with href attribute.
@tasneemtechno4014
@tasneemtechno4014 7 жыл бұрын
and what about showing 120 out of 140 in console?
@rachnasingh239
@rachnasingh239 6 жыл бұрын
Hi Mukesh.. Could you please do a session on Selenium in Sauce lab using Tunnel
@shaibalahmed7891
@shaibalahmed7891 3 жыл бұрын
Thank You Mukesh!
@joshnasravani963
@joshnasravani963 7 жыл бұрын
Hi Mukesh.... can u plz tell me how to handle captcha box using selenium webdriver....
@akhilagautham9997
@akhilagautham9997 7 жыл бұрын
Joshna Sravani you can't handle captcha using selenium web driver
@nikhilkanojia1683
@nikhilkanojia1683 8 жыл бұрын
Hi Mukesh , the code work fine, but i got this error when it was verifying the links: java.net.MalformedURLException: unknown protocol: javascript for 2 urls, can we deal with these or ignore it?
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Nikhil Kanojia Hi Nikhil please use try catch I above video I used throw which wont handle the exception
@staslocovai
@staslocovai 3 жыл бұрын
Hi Sir , First of all you're great - i learned a lot from you . But i have to join the people who ask you about how to write an assert on this . Because we use TestNg and the Tests page must remain "clean" and i cannot write assertion in the method Thanks in advance Stas from Tel Aviv
@Mukeshotwani
@Mukeshotwani 3 жыл бұрын
No prob mates, loved your honesty. I will try to this scenario too.
@staslocovai
@staslocovai 3 жыл бұрын
Thanks a lot !)
@traghavendra9828
@traghavendra9828 5 жыл бұрын
Hi Mukesh, in website if the links contains pdf files how to get the count of that only pdf files.Pleass share the code eg: selenium Wikipedia if u click on external links u vil get down with lists of pdf files associated with links
@jitendrasahu5493
@jitendrasahu5493 7 жыл бұрын
Very Helpfull vidio sir
@Ravi-qx8gg
@Ravi-qx8gg 5 жыл бұрын
Super explanation
@bhargavsr84
@bhargavsr84 8 жыл бұрын
Hey Mukesh, This is really a good one and thanks for sharing it. Really appreciate your efforts. Can you please let us know how to find out broken links for the entire site instead of a single webpage. For example: i want to broken links for entire website of learn-automation.com/.
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+bhargav sr You can pass url as the parameter then it will check.
@pavankumar-os3op
@pavankumar-os3op 8 жыл бұрын
could you explain what are Desired Capabilities in Selenium WebDriver
@HarshVardhan-ws4cq
@HarshVardhan-ws4cq 7 жыл бұрын
Hi Mukesh.. Few links are missing using this code. Suppose 31 links are thr, but status coming for 25 links PLz explain ..why ?
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
It means some link will not have href attribute
@HarshVardhan-ws4cq
@HarshVardhan-ws4cq 7 жыл бұрын
No..actually some of the links having response code...301 (permanently moved)...as you have used condition (==200) that why i was missing few links..better to use (response code
@amanmittal5848
@amanmittal5848 2 жыл бұрын
happy to all
@mudaseer21
@mudaseer21 4 жыл бұрын
nice mukesh
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
Thank you Ahmed 🙏
@21suhana
@21suhana 4 жыл бұрын
Hello Mukesh, Thank you for your effort..I tried your technique but I'm unable to get links that are broken (404 and 500 errors)..I see "ok" message for even broken links..Any help would be highly appreciated
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
Hi Suhana, can you share your code? which application you have used?
@21suhana
@21suhana 4 жыл бұрын
@@Mukeshotwani public class VerifyLinks { public static void main(String[] args) { WebDriver driver=new FirefoxDriver(); driver.manage().window().maximize(); driver.get("www.google.co.in/"); List links=driver.findElements(By.tagName("a")); System.out.println("Total links are "+links.size()); for(int i=0;i
@21suhana
@21suhana 4 жыл бұрын
FYI I'm using company website
@priyankagolewal3502
@priyankagolewal3502 7 жыл бұрын
please provide video for broken images also. what is the difference between HttpClient and HttpURLConnection? in some sites, I saw that they are using HttpClient to test broken image
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
HTTPClient is the library to test API’s. HTTPURLconnection is the class to connect to sever through http protocol
@priyankagolewal3502
@priyankagolewal3502 7 жыл бұрын
and how to test broken images?
@suryawanshiswapnali8834
@suryawanshiswapnali8834 7 жыл бұрын
HI Mukesh, Executing same code. But getting total number 53 but it's showing only one URL-->OK response. url->google.com. What could be the reason.
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
Hi Swapnali, Check response code as well if the code is coming in 2XX category then all will be passed.
@praveshchourasia9688
@praveshchourasia9688 6 жыл бұрын
Hi Mukesh, I just copy paste code from the link you provided and getting following error:- Exception in thread "main" java.lang.Error: Unresolved compilation problem: at TestCases.VerifyBrokenLinks.main(VerifyBrokenLinks.java:13) What could be the possible reason?
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hi Pravesh, Have you tried writing the code by yourself. If you still have issue then you have to debug your code and check. kzbin.info/www/bejne/qIm7lnucq8eXmtE
@shreyanshjain2347
@shreyanshjain2347 8 жыл бұрын
very nice!
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Shreyansh jain Thanks Bro
@karna1surya41
@karna1surya41 2 жыл бұрын
Thank u so much sir
@zainykhokhar
@zainykhokhar 8 жыл бұрын
I did try from my end, plz let me know if there is any other way, right click on page, view source page> , in source page by finding link, got (Attribute, tagname with value). then thru firepath, i wrote dynamic xpath, //a[@class='accessible_elem'] then found its hidden element. plz let me know if there is any other way to find link????
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Zain Khokhar Hi Zain I have another way 1- get all a tag and get href attribute and pass url in get method and check if any page title contains page not found the mark as broken. if you are thinking that this will take high execution time then please let headless browser in this case. Below video will help you for headless kzbin.info/www/bejne/mnanpZlur6-Hgck
@sourisengupta
@sourisengupta 7 жыл бұрын
Hi Mukesh, what if we get SSLHandshakeException when we are doing httpURLConnect.connect(); How to handle this situation?
@jayantiborde899
@jayantiborde899 5 жыл бұрын
Hello Sir, I have applied the broken link script to my application but & it showed me the expected result but the question comes how can i identify in the UI where the Link is not working or giving Wrong, what is the way that I can explain to the developer that this is the particular space where you have given the wrong links
@Mukeshotwani
@Mukeshotwani 5 жыл бұрын
Hi Jayanti, you can capture text along with URL so that you will get to know which link is broken.
@Imrankhan-xw4me
@Imrankhan-xw4me 7 жыл бұрын
Hi Mukesh, I used your same code. But it was not getting executed after the httpURLConnect.setConnectTimeout(3000);. It was stuck in this stmt. it was not moved to the next stmt i.e. httpURLConnect.connect();. Can you please guide me?.
@Imrankhan-xw4me
@Imrankhan-xw4me 7 жыл бұрын
I requested others also. Kindly Advise me...
@sharmishthaneogi5669
@sharmishthaneogi5669 7 жыл бұрын
Hi Mukesh, I tried the code provided by you. For the first time, it ran successfully. But after that, I am keep on getting "connect timed out". Could you please help me with this.
@upendrad6081
@upendrad6081 8 жыл бұрын
Hey Mukesh, this is Upendra again. This post I am putting related to this video only. I tried to test with our applications. For some links I am getting response as "Moved Permanently" and "Moved Temporarily". I am getting this in else part of the below code. Can I know what does it means? if(httpURLconnect.getResponseCode()==200){ System.out.println(linkURL+" - "+httpURLconnect.getResponseMessage()); } else{ System.out.println(linkURL+" - "+httpURLconnect.getResponseMessage()); } And anything got on my other post. You will save my life if you find something for me.Please... Thanks, Upendra
@upendrad6081
@upendrad6081 8 жыл бұрын
+Upendra D Sorry Mukesh, I got the answer. Whichever links are redirecting to some other links then those are giving these response. I should have checked before posting this. Sorry man. But can you please find a way to my other comment in this video...
@monil.joshi4
@monil.joshi4 4 жыл бұрын
How to do it recursively I am talking about nested links.. like if you go through aws or Android documentation you can see there are multiple hyperlink on the same page. So if I sum it up I am redirecting to home page then it has 100 links out of which I navigate to first one it has another 50 links again I take first one out of 50 and it has some 20 links So how can I traverse and validate these 20 links then 50 links and validate same for rest of 99 out of 100 links
@GinShu.
@GinShu. 8 жыл бұрын
plz post video on selenium grid,,or sugesst me some,,,
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
Hey Neeraj yes i have planned will upload soon.
@GinShu.
@GinShu. 8 жыл бұрын
thnx for the prompt reply...
@shubhamshinde2499
@shubhamshinde2499 7 жыл бұрын
Its working as per expections for single URL. But when i redirect website using selenium webdriver code it is giving "org.openqa.selenium.StaleElementReferenceException: stale element reference: element is not attached to the page document" Can we write the code for this?
@zainykhokhar
@zainykhokhar 8 жыл бұрын
Mukesh,,, Really nice post as usual, and really like they way you teach. how we will know if some or one link is broken. For example in facebook signup page this link not found "facebook.com/allactivity?privacy_source=activity_log_top_menu - Not Found - 404" how we will find the link is belong to which element?
@Mukeshotwani
@Mukeshotwani 8 жыл бұрын
+Zain Khokhar Hi Zain in this case you have to check the title and verify the same because the above code wil check 404 only.. above facebook example is not for broken link
@rrr_earn
@rrr_earn 5 жыл бұрын
how can i find broke url link in youtube description url working or not
@Mukeshotwani
@Mukeshotwani 5 жыл бұрын
Hi Rishu, here is the link learn-automation.com/find-broken-links-using-selenium/
@pallavisenapati8214
@pallavisenapati8214 7 жыл бұрын
Can you please add video for broken/invalid images.Thank you
@Mukeshotwani
@Mukeshotwani 7 жыл бұрын
HI Pallavi same program will work just you have to use src attribute for images.
@richaranjan6555
@richaranjan6555 3 жыл бұрын
Hi Sir, Line number 50.. HttpsUrlConnection one.... Please help me to understand that. HttpUrlConnection is not an Interface.. it is a class . It looks like we are typecasting URL to HttpUrlConnection. Please explain sir. Thank you in advance.
@shruthimp4945
@shruthimp4945 6 жыл бұрын
Hi Mukesh, I tried to implement assertion for the script as said in the assignment. I am getting error in a mid quoting translate.google.com/?hl=en&tab=wT - forbidden - 404 expected [200] found [403]. I tried to open the link having this msg. It was of Google translate. It opened and worked fine. Also when I run the script you have provided without assertion that script is working fine. Can u please help with this assignment.
@abraham2961
@abraham2961 5 жыл бұрын
Can anybody tell me how to verify each link like if we click on some link it will navigate to other pager there we check like this
@Mukeshotwani
@Mukeshotwani 5 жыл бұрын
Hi Rehan, I would recommend you to use API for checking broken links. If you still want to check in such manner then follow below approach. Click on Link It will open another tab or window. Switch to new window verify title should not be blank or url or page source should not contain 404 error.
@surendharrt2843
@surendharrt2843 7 жыл бұрын
hi mukesh. i got this below error when i click a button how to fix it???? org.openqa.selenium.WebDriverException: unknown error: Element is not clickable at point (1130, 27). Other element would receive the click: . if u have time pls give some solution for me..
@manikandanparthiban4165
@manikandanparthiban4165 7 жыл бұрын
Is there a way to handle Authentication Required popup? Have to enter username and password. Thanks
@navnaawie6016
@navnaawie6016 3 жыл бұрын
Hi sir , I am using your code but sometimes i get null response and sometimes ok what does null signify even though the link is working why it is showing null Thank you in advance
@Mukeshotwani
@Mukeshotwani 3 жыл бұрын
Hi Nav, some href have null values which points to same page. In your code you can handle null values.
@vijaysavale5928
@vijaysavale5928 6 жыл бұрын
hi sir connect(); method doesnt highlighted in my code by passing the object httpurlconnect
@Mukeshotwani
@Mukeshotwani 6 жыл бұрын
Hi Vijay, please cross check with below code learn-automation.com/find-broken-links-using-selenium/
@olenarogalska4085
@olenarogalska4085 7 жыл бұрын
Hi Mukesh! Thanks for you created this channel! It's my "holy book" (or better say "holy channel" :) ) for so many everyday stuff in automation! Your script for http protocol works just perfect, but for https protocols I have 2 scenarios. №1scenario for link "websitename" I used if (httpURLConnect instanceof HttpsURLConnection) { HttpsURLConnection httpsURLConnect = (HttpsURLConnection) httpURLConnect; .......... and it works fine. №2 scenario for "www.websitename" the case is caught by a catch block. Any clue how to fix this? Thanks!
@ilyasyar
@ilyasyar 4 жыл бұрын
How can we find broken links from entire website? not only from webpage? please. sir.
@sandeepkumar1640
@sandeepkumar1640 7 жыл бұрын
Please provide image and image text validation process.
@tsachu9212
@tsachu9212 4 жыл бұрын
if the link is of blob, how to get the response codes?
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
Hi Achu, can you explain me your requirement in detail?
@tsachu9212
@tsachu9212 4 жыл бұрын
Yeah. The solution you have provided will work if src='someurl". But nowadays contents are like src="blob:someurl". Blob is nothing but generation of url at run time based of url memory address. All azure based data stored websites are constructed of this way. For example, inspect current page and try to take url of this video from video tag.
@Mukeshotwani
@Mukeshotwani 4 жыл бұрын
Great will check this and will let you know..
@tsachu9212
@tsachu9212 4 жыл бұрын
Thank you
@laxmirukka3028
@laxmirukka3028 8 жыл бұрын
pls share the code
@AshishDubeyash4you
@AshishDubeyash4you 6 жыл бұрын
Hi Mukesh, In this line System.out.println(linkURL+"-"+httpURLConnect.getResponseMessage()+"-"+HttpURLConnection.HTTP_NOT_FOUND); Why are you printing +"-"+HttpURLConnection.HTTP_NOT_FOUND Can you please explain?
What Is JavaScriptExecutor In Selenium Webdriver
6:29
Mukesh otwani
Рет қаралды 27 М.
$1 vs $500,000 Plane Ticket!
12:20
MrBeast
Рет қаралды 122 МЛН
Вопрос Ребром - Джиган
43:52
Gazgolder
Рет қаралды 3,8 МЛН
«Жат бауыр» телехикаясы І 26-бөлім
52:18
Qazaqstan TV / Қазақстан Ұлттық Арнасы
Рет қаралды 434 М.
How To Capture and Validate Tooltip in Selenium WebDriver
17:24
Mukesh otwani
Рет қаралды 22 М.
Find broken images | Playwright Typescript  - Part 100
8:34
LetCode with Koushik
Рет қаралды 3,1 М.
How To Perform Drag and Drop in Selenium WebDriver
19:06
Mukesh otwani
Рет қаралды 30 М.
How to handle hidden webelements in Selenium Webdriver
21:19
Mukesh otwani
Рет қаралды 126 М.
How to find broken links & Images using Selenium Webdriver
45:35
Naveen AutomationLabs
Рет қаралды 99 М.
Desired Capabilities and Chrome Options in Selenium WebDriver
13:01
H Y R Tutorials
Рет қаралды 44 М.
$1 vs $500,000 Plane Ticket!
12:20
MrBeast
Рет қаралды 122 МЛН