Better way to test multiple websites through automation - web

I am trying to find a better automation tool to perform the websites testing automatically to identify the bugs using various mobile devices and browsers.
Tried with various no code automation tools and Browserstack and Lambdatest as well. but not able to acheive it perform automatically.

Selenium seems to be the most popular option. However, I suggest Playwright. It has unique features to be able to open new pages, new tabs, new browsers and new windows with its Browser, BrowserContext and Page concept.

Related

how to create executable with puppeeter in neutralino.js

I want to write a web scrapper / automated page-clicking desktop application, but with GUI for the end-user. The point is that a the user can go to some website, log in and then select the operations that he wants to automate through my application GUI. Such as writing a chat message or clicking a page automaticaly, the way they want. In the best cases without reaching out to any back-end.
I do not have direct access to the api of these pages.
I wanted the solution to be multi-platform (at least windows, macos) and for it to be a full-fledged product. So I have to generate some executable that someone will download, install and be ready to go.
I'm am thinking about using neutralino and puppeeter, but this is relatively new technology and there are no information how to plug in the testing automation tools. Is it even possible to create installable package without problems with chromium paths? Does anyone have a knowledge how to do it?
Thanks

Browser Extension the "Injected way" a cross-browser extension that include a JS from a distant server

I've found this nice article about the "injected Way", but the author never finished it :
http://hightechstartups.blogspot.ch/2012/05/different-way-of-developing-browser.html
I would like a bare bone cross browser extension, without any 3rd party extensions or framework (to be as light as possible and not dependant on a 3rd party) that would load Jquery and a JS from a distant server and the ability to load it before or after the page is fully loaded.
I've read a lot of topics about the subject, but since IE10, Chrome 26 and FF20 are out with their new cross-link limitations, i was wondering if somebody had ressources, source code or tutorial about the following requirements :
I need :
Cross browser extension supporting (IE 8+ or 9+ worse case, Chrome
26+, FF20+, Safari)
Ability to inject a single JS hosted on another server. Inserts a script tag that references a javascript file in the head of the HTML
page and then be executed
Not be dependant on a third party extension (greasmonkey) or framework (Kango, Crossrider)
Ability to load before or after the page is fully loaded
This method allows me to customise the browser extension depending on the user's location and it also avoid having updates as the JS is updated on each page refresh.
I'm aware of the downsides, but i would like to achieve this.
I'm aware of cross browser framework like Kango or crossrider, but both don't fit me needs.
The closest example i could find is this How can I run a <script> tag that I just inserted dynamically from a BHO
but it only covers IE and as i got very little Csharp experience, i would like to see a full example to understand it properly and learn from example.
I would LOVE to have a few examples, even if it's not cross-browser (IE being the worst part for me).
Thanks a lot for your support !
Update1:
About Kango and Crossrider, Kango is 2000$ if you want to use IE and for Crossrider you're required to be distributed and monetized by them.
I've managed to code for IE and Chrome, but i was looking for an "elegant" way and figured it was the best place to ask given the level of knowledge of people on this site.
For the installer i currently use NSIS, but i'll test Wix too.
Finally i guess the only way for me would be to learn C++ and .net to get it to work with IE, but if anyone could provide more source code it would be great to test speed and compatibility and discuss here what's the best solution.
Why do Kango or Crossrider not fit your needs? Both frameworks allow you to manipulate the page's DOM (which is what you want):
Kango: Adding content script
Crossrider: documentation, example code
If you want to code your own solution, take a look at the relevant documentation:
Content scripts (Chrome)
The Page mod Jetpack API (Firefox)
Injected scrips (Safari)
Injected scripts (Opera)
Internet Explorer does not natively support extensions. It took me about 80 hours to create a stable and reliable IE extension which supports cross-site AJAX, a (preference) storage method and injection of scripts as early as possible in any frames based on its URL. I developed and tested the extension with Visual Express 2010 on Windows XP and Windows 7, for IE 8-10 (the extension might work on IE6/7, but I decided to not support these ancient and rarely used browsers).
First, I wrote an extension in C# based on LiveReloadIEExtension (a sample IE extension, which in turn is based on this Stack Overflow answer - see also this blog post). It was functional, but it required .NET 4, lacked support of frames, and it's relatively slow.
So, I decided to write an IE extension from scratch in C++. A good starting point is available at http://www.wischik.com/lu/programmer/bho.html: Sample code for C++ BHO, which changes the document's background based on key/mouse events. I've also learned a lot by looking at other code samples on CodeProject, topics on the MSDN forums, questions and answers on Stack Overflow, lots of other blogs, and the MSDN documentation:
DWebBrowserEvents2 interface lists several events which you use to find an appropriate injection point.
Scripting Object Interfaces (MSHTML) lists even more interfaces. You'll be mainly interested in the iHTMLDocument, iHTMLDocument2, ... interfaces.
After creating the IE extension, you want to deploy it of course. I used Wix toolset to create a MSI.

C# code for automating a website

All I want is to record the actions I perform in a website and have to get the code generated for the same in c#.To make it clear,I juss want to run the code so that the manual activity is performed automatically.Any help would be great.Thanks a lot.
Visual Studio has web test recording, it actually can generate code for you. This will record integration between browser and server. So if you rerun, server will think that you are doing something. This option is not browser automation.
WatiN is another option. This time, it is browser automation tool. It has recording tool too.
Third option is Selenium, very similar to WatiN. There are many tools to record Selenium scripts. Most supported one is Selenium IDE.
All tools, are quite easy to work with, and you can find good tutorials on the respective sites.
My best guess, of your needs is that you need #2 or #3. It looks like #3 is more active/mature tool, but I used both with success, so no problem to choose #2.
If you will go with #1, check what edition of Visual Studio you use. I am afraid, Web Testing could be available only in top editions, like Ultimate.

Import/export google mail (was "[is it possible to] create custom Google Lab")

Is it possible to create a custom Google Lab project? Or do Google Engineers have to create them? I'd like to integrate Gmail with another web application on a company web server.
If that is not possible, is there a way to import/export google mail in some format (ie: XML, HTML, etc..) for a specific gmail user or group of gmail users?
No.
You're looking for the IMAP protocol, which allows you to interact with Gmail messages.
No, it's not possible. Google Labs projects are Google's own experiments, not something you can add to yourself.
As Nadir Muzaffar said, maybe Gmail's API is what you're looking for: https://developers.google.com/gmail/
I'd like to add that you may create a browser extension.
You may start with experimenting with Developer toolbar (F12) and then pack your javascript to an extension.
If you use I.E. Chrome, see I.E. https://robots.thoughtbot.com/how-to-make-a-chrome-extension or try to look at your current extensions in order to understand how it's working ( ~/.config/google-chrome/Default/Extensions/ or ~/.config/google-chrome/Default/Extensions/ )
Note that if GMail changes, your extension may not work anymore.

Hosting Google Apps UI in my app

I'm investigating the possibility of re-using Google Apps/Docs in a local hybrid desktop/browser application.
I've been going through the Google documentation on manipulating docs, eg. the Spreadsheet. I can't seem to find any info on actually hosting the UI. Is this possible, or does it require some form of permission from Google?
You want to basically embed an browser control in your application pointed at the URL of a Google Apps doc? You could use the Google Document List API to retrieve the documents for a user, then use the URLs of those documents in your embedded browser control.
You don't need Google's permission to do that; you're writing a browser with some extra smarts built in.
What do you mean by "hosting the UI?" These apps are HTML/CSS/JavaScript. Are you thinking about embedding them in AIR or Titanium, or in some kind of web control in another app?
i briefly looked into doing this, and figured if i really wanted to i could just load the gdocs page content dynamically, and use javascript to strip away the superflous elements like header and footer. but instead i'll probably just use an OS alternate because they have come a long way and I want rich hooks.

Resources