Browser-chrome tests on the Fennec front end – Summary

The wonderful program of the Google Summer of Code is nearing to a close. And it’s time the student participants finish their last bit of coding. The ultimate aim of this program is to encourage more people to venture into world of Open Source. So am I inspired?
After 3 months since the coding began, I have done some work. Though effectively I could complete 50% of it. But there were factors not in favour of me. But I relish these 3 months and I definitely would look forward to contribute much, much more.
The aim was to write automated tests to test the fennec front end, mainly the Preferences, Awesome bar, Zooming/Panning and Download Manager. I started on the preferences, which was broken into 4 main tests – basic, checking on/off states, text and colors, and the core functionality. Since being the easiest of the lot, I assumed it would take less time. It was not to be. I submitted the first patch for the basic testing, which got landed pretty soon. Then there was a long period were I had times when I scratched my head wondering what to do next. At times the tests simply timed out, which was simply frustrating. The mobile had landed the e10s, which kind of messed up with the fennec build. And so there was a lull, unable to test what I have written. Finally things began to change for the better, I started working and testing. I submitted all the patches for the Preferences test, of which one landed. Few problems still persist, but I am confident that these would be sorted out.
Then jmaher suggested I start with zooming/panning test. I thought this to be the toughest of the lot. But I began to understand ( I had a bit of the testing in the preferences tests, so there ). And soon I had written the full test in a very short time. But the problem with this test was the use of timeouts, that which simply waits for certain amount of time, to wait for the zooming or panning of pages. Instead it was desired that I wait for events to occur, events that notify whether the zooming has ended or panning has stopped ( the extra problem with panning was the kinetic scrolling, which made it hard to predict, theyby cannot wait for the mouseup event ). So this patch cannot be landed without necessary changes.
I also written a small test to check for favicon visiblity and also the display of title in the awesomebar. But after the e10s were landed, there seemed to be problems with awesomebar, at times the autocompletepopup after focussing on the awesomebar won’t finish loading. And this became the stumbling block for the main awesomebar tests, and I made no further progress in the test.
As for download manager, well it is the toughest of the lot for me. The code behind the download manager was hard to comprehend, and even after a week pondering over it, I managed no result. Now though I have a pretty good idea of how to conduct the test, but it won’t make it before the firm “pencils down” date, so you will see me posting about this test in this blog. 🙂
So, am Inspired? Inspired!? That’s an understatement actually. I’m fired up! Well you can say that because Mozilla invited me to the awesome Mozilla Summit 2010. But the real joy was the project itself. The kind of work that was involved, designing, writing code, testing and deploying. These were the words that popped up so many times during my software engineering classes with me making little sense of them. Now after this, I realize how important these terms are. Technically I learnt more of javascript, and also a bit of python and how they use them. And to be in the middle of a great product on the rise is an awesome experience. It’s fun being a member of the Mozilla Community, and I love to contribute more for the benefit of the people of the World. Thank you Google for giving me this great opportunity to be a part of a wonderful open source organisation.

The wonderful program of the Google Summer of Code is nearing to a close. And it’s time the student participants finish their last bit of coding. The ultimate aim of this program is to encourage more people to venture into world of Open Source. So am I inspired?
After 3 months since the coding began, I have done some work. Though effectively I could complete 50% of it. But there were factors not in favour of me. But I really relish this time, and I definitely would take forward and contribute.
The aim was to write automated tests to test the fennec front end, mainly the Preferences, Awesome bar, Zooming/Panning and Download Manager. I started on the preferences, which was broken into 4 main tests – basic, checking on/off states, text and colors, and the core functionality. Since being the easiest of the lot, I assumed it would take less time. It was not to be. I submitted the first patch for the basic testing, which got landed pretty soon. Then there was a long period were I had times when I scratched my head wondering what to do next. At times the tests simply timed out, which was simply frustrating. The mobile had landed the e10s, which kind of messed up with the fennec build. And so there was a lull, unable to test what I have written. Finally things began to change for the better, I started working and testing. I submitted all the patches for the Preferences test, of which one landed. Few problems still persist, but I am confident that these would be sorted out.
Then jmaher suggested I start with zooming/panning test. I thought this to be the toughest of the lot. But I began to understand ( I had a bit of the testing in the preferences tests, so there ). And soon I had written the full test in a very short time. But the problem with this test was the use of timeouts, that which simply waits for certain amount of time, to wait for the zooming or panning of pages. Instead it was desired that I wait for events to occur, events that notify whether the zooming has ended or panning has stopped ( the extra problem with panning was the kinetic scrolling, which made it hard to predict, theyby cannot wait for the mouseup event ). So this patch cannot be landed without necessary changes.
I also written a small test to check for favicon visiblity and also the display of title in the awesomebar. But after the e10s were landed, there seemed to be problems with awesomebar, at times the autocompletepopup after focussing on the awesomebar won’t finish loading. And this became the stumbling block for the main awesomebar tests, and I made no further progress in the test.
As for download manager, well it is the toughest of the lot for me. The code behind the download manager was hard to comprehend, and even after a week pondering over it, I managed no result. Now though I have a pretty good idea of how to conduct the test, but it won’t make it before the firm “pencils down” date, so you will see me posting about this test in this blog. 🙂
So, am Inspired? Inspired!? That’s an understatement actually. I’m fired up! Well you can say that because Mozilla invited me to the awesome Mozilla Summit 2010. But the real joy was the project itself. The kind of work that was involved, designing, writing code, testing and deploying. These were the words that popped up so many times during my software engineering classes with me making little sense of them. Now after this, I realize how important these terms are. Technically I learnt more of javascript, and also a bit of python and how they use them. And to be in the middle of a great product on the rise is an awesome experience. It’s fun being a member of the Mozilla Community, and I love to contribute more for the benefit of the people of the World. Thank you Google for giving me this great opportunity to be a part of a wonderful open source organisation.

Week no 10 – Bugs Bugs Bugs!

The summit has given me energy to go all in for the automated tests ( also partly that there is only a month left! ). This week was quite engaging. I was working on multiple tests at a time. I filed patches for checking the states of the preferences options and the awesome-bar url check and the favicon check. Also was engrossed on the tests on core functionality of the preferences, as also tests on the tab loading behaviors of the awesome bar.

The one problem I had with writing the patches was the use of window.messageManager. The mobile team would like every tests to use messageManager instead of eventManager and waitFor, for like waiting for events and pages to load. But it is not the case in mine though. I tried using them for page loads, but it does not wait and often the results show fail which it is not. Anyways the guys are working on it, and I have used the other two options for this.

The core functionality tests are the major stumbling block for now. One of the tests to check whether the remember passwords dialog is prompted when the option is switched off. But the problem is that once a textbox is clicked, the form helper loads. After entering a string to it ( password ), it cannot “click” the next element, that is the submit button. Actually it cannot do any clicks on other elements. Anyways I think this issue will be resolved and by the next week I am hoping to see a patch for it done.

The next step would be to work on more tests. I would be concentrating on the preferences options ( checking text and color ), the awesome bar and start work on the download manager. A busy week ahead!

Week no….. ah I lost the track!!!

Yeah, seriously I lost the track on the current week number, all because of the awesome awesome Mozilla Summit 2010. Not only a week that was gone for the summit ( that includes 2 days of flight), but also a week before that because of the visa refusal ( more on that in the coming blog post(s!) ).

So what about the GSoC? Sure, it’s lagging behind, maybe by a week or so. But I got all the things on note and surely be taken care of with few extra hours of work. The best part is that I met my mentor there ( Joel Maher ) and also other people that count like Mark Finkle, Clint Talbert, Gerv, and many others. The summit was a enthralling experience and has only made me more committed to Mozilla, Mozilla ROCKS!!!

So the next few weeks will be tight for sure, with the mid-term evaluation round the corner (July 16). But I am pretty confident that I can pull the things through, that I have got all things in order and now more than ever I know what to do (Pretty strong words eh!). The summit has given me whole bunch of experiences that has enriched my knowledge on the mobile firefox and other related stuff. The discussion with jmaher was great and he turns out to be an amazing guy with tons of experience in the field of automation. I feel so lucky to have him as my mentor and now we are both ready to put things on the fast track and get them done for the benefit of getting the first version of Mobile Firefox into the many phones round the world!

So the next week, I’ll be concentrating on putting new patches for testing the preferences options like the homepage selection, checking the core functionality, and also text and colors. Also I am hoping that I’ll put a patch through for testing the awesome bar favicon and trivial stuff. So that’s the plans for the week and I will be updating the next week.

Oh yeah, for the records, I’ll put this week as week no. 9 as I can find it in the calendar… 🙂

Week no 6 – First Patch through!

Due to unfortunate circumstances, I had to skip off week no. 5 post. Anyways, here I am with the latest updates of what has happened so far in the automation tests for Fennec front end.

The first patch, that was basic panning of preferences pane of Fennec, has undergone a lot of ridiculous changes (which you can see from this bug489158). But finally I found out the way to compare the panning values with that of variables that depend on the Fennec size. This way I got rid of all the hard-coded values except one which has no possible way to find out. After all that and few silly changes Continue reading

Week no. 4 – First patch for preferences test

So now into the 4th week of the fennec front end automated tests project. The previous week had has seen less activity, but the main highlight was the submission of the first patch related to the project.

The patch was related to the basic panning of preferences, like checking out whether the preferences stays the same when the user enters and exits the preferences. It was a simple one but a step forward in the direction of greater coverage of the Fennec features. And the patch isn’t perfect as always. I used hard-coded values to check for the panning, but it isn’t proper to use them. Instead I must use global values. So gotta check that out. Also Mark Finkle also suggested a few improvements.

I’m hoping that I get patch “patched up” this week and also submit patches of the rest of the test coverage of the preferences this week. This is indeed challenging but great fun, the beauty of how we can test the parts of the browser using js!

Automated Tests in Fennec – Week No.3

Where did the weeks one and two go? Well, I just didn’t document it. Anyways, a recap of what happened the past two weeks.

I really began to work on this project on May 10. And for nearly one and a half week, I’ve been doing what I posted earlier. In the end of last week, I began to make real progress, wrote down 50% of the preferences test, and they seemed to work. I’m not saying it’s done, the review is left. What I did now is to concentrate on the small details of the preferences options in Fennec like to see whether the About Fennec leads to the About Fennec page, checking to see whether the on/off states of all the options remain as it is even if I closed the preferences, verify the various button states and panning the preferences view.

Now I’m concentrating on testing the preferences list for selecting home page, verifying the core functionalities of preferences and zooming states. It has been exhausting trying to get the methods I want to use for testing. Thanks to Mark Finkle and Joel Maher (mentor.. 🙂 ), I’m able to crack down on the issues and hopefully get the tests for review this week itself. Still lots to work to do in this, and also for other tests (zooming/panning, download manager, awesome bar).

Yup, pretty hurried posting. But can’t think of anything else as my mind is full on how to go about testing that particular button, so on. I’ll look to update this post with some snapshots, may not be worthwhile, but would benefit wanna be Fennec contributors. So sionara folks!