Summer of Code/2014/Gp94/Activity Unit Tests

About you

What is your name?
My name is Gaurav Parida, and I am a 2nd year undergraduate student at International Institute of Information Technology (IIIT), Hyderabad.

What is your email address?
My institute email address is gaurav.parida@students.iiit.ac.in and my alternate email is gparida94@gmail.com

What is your Sugar Labs wiki username?
My username on sugarlabs trac is gp94 and my username on g.sl.o is gauravp.

What is your IRC nickname on irc.freenode.net?
My IRC nick name is gp94

What is your first language? (We have mentors who speak multiple languages and can match you with one of them if you'd prefer.)
My first language of communication is English and I am also comfortable with Hindi.

Where are you located, and what hours (UTC) do you tend to work? (We also try to match mentors by general time zone if possible.)
I live in India, so the time difference in UTC and IST is +0530Hrs.I can work comfortably from afternoon to midnight. I will try to be mostly active when most of the mentors come on IRC.

Have you participated in an open-source project before? If so, please send us URLs to your profile pages for those projects, or some other demonstration of the work that you have done in open-source. If not, why do you want to work on an open-source project this summer?
Nowadays, most of the softwares that I use are open source, eg- Linux kernel, Mozilla Firefox, VLC player and etc. There has been buzz about FOSS. I had known about GSoC from the seniors of our college. Now, that I am more acquianted in software development and practices, so thought of giving it my level best to contribute towards FOSS and get involved in it, through SugarLabs. This is my first time contribution towards Open Source Development.

About your project

What is the name of your project?
Activity Unit/UI Tests

Describe your project in 10-20 sentences. What are you making? Who are you making it for, and why do they need it? What technologies (programming languages, etc.) will you be using?
Sugar has many activities, which come preinstalled. As a part of my GSoC project, I will have to write Unit tests and UI Tests for the 12 fructose activities. The unit tests involve the usage of the unit test library to run the tests and the UI tests use the ATK SPI to simulate the running of the application. All the code is written in Python. The unit tests have the purpose of confirming the proper operation of the non-UI function that is used in the implementation of a feature in the activity. The UI tests focus on simulating the screen of a normal user and simulates the click and the operations that a normal user would do in an activity, in a very accelerated fashion. As a part of the project I will have to develop Test Suites for the respective activities. The test suite will be divided into two parts, the unit test and the integration/UI tests. Along with the commencement of the making of the test suite, I will also update the testing guide for the activities in sugar. The testing guide will have all the steps that are required to successfully test an applications and will document on how to write your own tests. If time permits, I would also write tests for the core sugar and sugar-toolkit-gtk3 and more activities.The deliverables of the project include writing of the testing guide for activities and also the test suites of the respective activities.

What is the timeline for development of your project? The Summer of Code work period is from May 19 - August 22; tell us what you will be working on each week. (As the summer goes on, you and your mentor will adjust your schedule, but it's good to have a plan at the beginning so you have an idea of where you're headed.) Note that you should probably plan to have something "working and 90% done" by the midterm evaluation (27 June); the last steps always take longer than you think, and we will consider cancelling projects which are not mostly working by then.

Week / Days Work to be Done
22nd April - 5th May
(Pre-program preparation)
Study about unit and UI tests and install all the required activities.
6th May - 20th May
(Pre-program preparation)
Report back my results and clarify the doubts on the current research.
20th May - 27th May
(Week 1)
Review and write more unit tests and UI tests for the Calculate and Hello-world
28th May - 3rd June
(Week 2)
Write tests for Terminal / Log
3rd June - 10th June
(Week 3)
Write tests for Pippy / Write
10th June - 17th June
(Week 4)
Write tests for Browse / Chat
17th June - 24th June
(Week 5)
Write tests for TurtleArt
24th June - 1st July
(Week 6)
Mid-Term Evaluations - Buffer Week
1st July - 8th July
(Week 7)
Write tests for ImageViewer / Read
8th July - 15th July
(Week 8)
Buffer Week 1
15th July - 22nd July
(Week 9)
Write tests for TurtleArt
22nd July - 29th July
(Week 10)
Buffer Week 2
29th July - 5th August
(Week 11)
Start updating the Testing Guide of the activities on docs.sugarlabs.org
5th August - 12th August
(Week 12)
Expected Pencil Down Date
12th August - 19th August
(Week 13)
Polish up the tests, and manage the wiki page of the project and compile the content
19th August - 26th August
(Week 14)
Firm Pencil Down & Final Evaluations

I plan to continue working in the week, even if the weekly task has been accomplished. The activities chosen in the schedule is based on it’s respective vastness and intricacy and my acquaintance with them to write unit /UI tests for them.

Convince us, in 5-15 sentences, that you will be able to successfully complete your project in the timeline you have described. This is usually where people describe their past experiences, credentials, prior projects, schoolwork, and that sort of thing, but be creative. Link to prior work or other resources as relevant.
I have participated in many projects as a part of the college curriculum and my own interest. As a part of life here at IIIT, one has to not only manage completion of assignments but also seek for the overall growth. Here, we get the feel of deadlines, projects/assignments /presentations. Even under so much workload, we eventually complete them successfully. The projects that I have successfully completed is given below --

-- Built a clinic management web application called HealthMate, that won the Google Cloud Developer Challenge 2013 from India Region. It was built using Google App Engine framework and python.
Link - http://www.gcdc2013-healthmate.appspot.com

-- Built an evernote like application which is a notes taking and task scheduling web application as a part of college coursework. It was built using web2py and python.
Link - https://github.com/gauravp94/online_notes_web2py

-- Built a terminal that is simmilar to the linux terminal with functions like opening files and piping and etc. It was built as a part of the Operating Systems coursework. It was built using C language.
Link - https://github.com/gauravp94/C-terminal

-- Built a reddit like web application as a part of college coursework. It was built using web2py and python.
Link - https://github.com/gauravp94/reddit_web2py

-- Built a TCP client and server peer to peer implementation as a part of the Computer Networks course. It was built using C.
Link - https://github.com/gauravp94/TCP_FileTransferProtocol

-- Built a 2D and a 3D game in OpenGL as a part of the Graphics coursework. It was built using C++
Link - https://github.com/gauravp94/openGL-3DGame, https://github.com/gauravp94/openGL-2DGame

-- Built a simple wave mixer application using Python GUI tools(tkinter) and pyaudio library in python.
Link - https://github.com/gauravp94/wave_mixer_python

-- Built an Android application called BabySteps, which is foccused for Child and Infant Healthcare in India.
Link - https://github.com/gauravp94/Babysteps

-- Built an IRC Bot using python and twisted library to take logs of the sugar IRC channel. Link - https://github.com/gauravp94/sugar-IRC-LogBot

-- Have made a few applications like painting app using processing2.0 as a part of a coursera course online.
Link - https://github.com/gauravp94/processing_apps

I have been using python since last two years and I am pretty comfortable using it. I have used python as the programming language for many of my projects. Since, the summer break is the time when a student has lot of free time and one can adopt to new technologies and learn new things, meet new people, share ideas and make something useful. I feel that I can grasp new things and use them to successfully complete the project.

You and the community

If your project is successfully completed, what will its impact be on the Sugar Labs community? Give 3 answers, each 1-3 paragraphs in length. The first one should be yours. The other two should be answers from members of the Sugar Labs community, at least one of whom should be a Sugar Labs GSoC mentor. Provide email contact information for non-GSoC mentors.
Testing is one of the integral parts of software development, because it not only helps in realising the mistakes in the software but it also helps in inculcating the habit of good software development practices. The writing of tests makes the developers analyse the mistakes in the activities and analyse the various vulnerabilities. How will it impact the users? Now the teachers would, download the latest version of the given activity and then run the tests to accordingly verify the proper working of the activity and accordingly use it among all the students. It would make the software more reliable and easy to use.

Walter Bender email : walter.bender@gmail.com
Unit testing will give us much better stability and control over changes and it will make it easier to verify other platforms, which is ever more important for us.

What will you do if you get stuck on your project and your mentor isn't around?
If I need help, and there is no mentor to help, then I will first see for the regular contributors like ignacio, svineet, manuq, dnarvaez, walterbender, gonzalo, tch,...that may be present on IRC and seek their help, if the problem still persists then I will send a mail to the mailing list seeking for help, so that the mentor can see it whenever he comes online. Till then I will try to get involved in some other aspect/ part of the project.

How do you propose you will be keeping the community informed of your progress and any problems or questions you might have over the course of the project?
Well, before the start of the program, I have made a micro blog http://gp94me.tumblr.com/ , where I keep a daily log of the work that I do as a contributor towards the organisation. I hope to keep the blog updated so that people can see the updates and put in their feedback. Thus, all the progress will be recorded in the blog. If asked to maintain the record in the wiki, I will accordingly do so.

Miscellaneous

Send us a link to a screenshot of your Sugar development environment with the following modification: when you hover over the XO-person icon in the middle of Home view, the drop-down text should have your email in place of "logout".

Sugar req.png


Send us a link to a pull request or merge request you have made on a Sugar or Sugar activity bug.
I have been regular in the sugar community for a while and I have compiled all the work that I have contributed towards the project uptill now

1. sugar-docs Pull Requests

   Merged
https://github.com/sugarlabs/sugar-docs/pull/59
https://github.com/sugarlabs/sugar-docs/pull/61
https://github.com/sugarlabs/sugar-docs/pull/65
Closed
https://github.com/sugarlabs/sugar-docs/pull/60

2. sugar-build Pull Requests (Added an empty activities folder in sugar-build which was not being created earlier)

   Merged
https://github.com/sugarlabs/sugar-build/pull/26

3. sugar-toolkit-gtk3 pull requests (Implemeted the verbosity feature in unit tests)

   Merged (to be done after the release is unfrozen)
https://github.com/sugarlabs/sugar-toolkit-gtk3/pull/117
Closed
https://github.com/sugarlabs/sugar-toolkit-gtk3/pull/113
https://github.com/sugarlabs/sugar-toolkit-gtk3/pull/115
https://github.com/sugarlabs/sugar-toolkit-gtk3/pull/116

4. g.sl.o pull requests

   https://git.sugarlabs.org/browse/mainline/merge_requests/11
https://git.sugarlabs.org/write/mainline/merge_requests/3
https://git.sugarlabs.org/calculate/mainline/merge_requests/14
https://git.sugarlabs.org/read/mainline/merge_requests/4
https://git.sugarlabs.org/speak/mainline/merge_requests/3
https://git.sugarlabs.org/calculate/mainline/merge_requests/15

5. Other

   sugar-IRC-LogBot
https://github.com/gauravp94/sugar-IRC-LogBot

I have been also reporting bugs at the bugs.sugarlabs.org

   http://bugs.sugarlabs.org/ticket/4735
http://bugs.sugarlabs.org/ticket/4733

Describe a great learning experience you had as a child.
When I was 6 years old, I was always interested on knowing how things worked. My dad had bought me a electronics set, where I plugged in a DC motor to a battery and made a Fan. Intrigued by this success, I thought that the fan will rotate faster if I plug it to the AC port. On doing so, a short circuit occurred and from that I learnt that without the guidance of the elders, working things can go awry.

Is there anything else we should have asked you or anything else that we should know that might make us like you or your project more?
I think that, it is a very noble job to make something that helps in improving the way teaching is done and makes the subject more interactive and interesting for the student to understand and grasp. The OLPC and the SugarLabs project should be adopted in more and more countries. I feel humbled to be be a part of such a good cause.