Difference between revisions of "Firefox Performance Testing : A Python framework for Windows"
(→In class Firefox Performance Testing Setup Configuration) |
|||
(201 intermediate revisions by 17 users not shown) | |||
Line 35: | Line 35: | ||
= Project Contributor(s) = | = Project Contributor(s) = | ||
+ | |||
+ | [[User:dwwoodsi|Dean Woodside]] (dean) | ||
+ | * Submitted an sh file that automates the tedious performance testing framework configuration | ||
+ | |||
+ | Alice Nodelman | ||
+ | *Discussed on the things that need to be fixed to improve and strengthen the framework | ||
+ | *Gave suggestions on the new Performance Testing framework | ||
[[User:Bhearsum | Ben Hearsum]] (bhearsum) | [[User:Bhearsum | Ben Hearsum]] (bhearsum) | ||
*Set up the VM for performance testing | *Set up the VM for performance testing | ||
− | *Helped with the debugging process for report.py, run_tests.py and ts.py | + | *Helped get me started with the debugging process for report.py, run_tests.py and ts.py |
+ | |||
+ | [[User:Mylau | Michael Lau]] (mylau) | ||
+ | *Added comments on the documentation for setting up Performance Testing framework for Windows | ||
+ | *Tested the new and improved Performance Testing framework (version 1) | ||
+ | *Gave constructive feedback on documentation (version 1) | ||
+ | |||
+ | [[User:Eor | Eva Or]] (eor) | ||
+ | *Tested the new and improved Performance Testing framework (version 1) | ||
+ | *Gave constructive feedback on new documentation (version 1) | ||
+ | |||
+ | [[User:djhamp-g | David Hamp Gonsalves ]] (inveigle) | ||
+ | *Gave pointers on flushing buffer | ||
+ | *Helped with some grammar and sentence structuring for documentation (version 1) | ||
+ | *Tested and gave constructive feedback on the framework (version 1) | ||
+ | *Looked into a batch file for automating configuration, gave pointers | ||
+ | *Tested and commented on the new framework (version 2) | ||
+ | |||
+ | [[User: robcee | Rob Campbell]] (robcee) | ||
+ | *Gave me a number of python tips :) | ||
[[User:Themystic | Tom Aratyn]] (mystic) | [[User:Themystic | Tom Aratyn]] (mystic) | ||
*Introduced Closures in Python | *Introduced Closures in Python | ||
− | |||
− | |||
− | [[User: | + | ==In-Class Contributors== |
− | * | + | Please let me know if I missed you out. I've only listed the people whom I've received comments from. Those of you who participated but isn't listed as an in-class contributor, please list your comments [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#In_class_Firefox_Performance_Testing | here]] |
+ | * [[User:Mdsouza|Mark D'Souza]] (mdsouza) | ||
+ | * [[User:Sherman|Sherman Fernandes]] (sjfern) | ||
+ | * [[User:Ankuswan|Aditya Nanda Kuswanto]] (vipers101) | ||
+ | * [[User:dmmanley|Dave Manley]] (seneManley) | ||
+ | * [[User:Cbguy1|Colin Guy]] (Guiness) | ||
+ | * [[User:mattar1|Mohamed Attar]] (mojo) | ||
+ | * [[User:mckwan|Man Choi Kwan]] (mckwan) | ||
+ | * [[User:RealMarkP|Mark Paruzel]] (RealMarkP or FakeMarkP) | ||
+ | * [[User:jbmossop|Jeff Mossop]] (JBmossop) | ||
+ | * [[User:melz|Melissa Peh]] (melz) | ||
+ | * [[User:Paul|Paul Yanchun Gu]] (gpaul) | ||
+ | * [[User:Vpmirand|Vanessa Miranda]] (vanessa) | ||
+ | * [[User:Pcvitori|Philip Vitorino]] (philly) | ||
+ | * [[User:PStD|Paul St-Denis]] (pstdenis) | ||
+ | * [[User:moe|Mohammad Tirtashi]] (moe) | ||
+ | * [[User:Cdolivei|Cesar Oliveira]] (cesar) | ||
+ | * [[User:Andrew|Andrew Smith]] (andrew) | ||
+ | * [[User:Bhearsum | Ben Hearsum]] (bhearsum) | ||
+ | * [[User:Eldavey|Erin Davey]] (davey_girl) | ||
+ | * [[User:themystic| Tom Aratyn]] (mystic) | ||
+ | * [[User:djhamp-g | David Hamp]] | ||
+ | * [[User:dwwoodsi|Dean Woodside]] (dean) | ||
= Project Details = | = Project Details = | ||
+ | |||
+ | ==Improved Documentation== | ||
+ | ===Latest=== | ||
+ | [[New_Firefox_Performance_Testing_Documentation | New Firefox Performance Testing Documentation]] | ||
+ | ===First Attempt=== | ||
+ | [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows_Documentation | Performance Testing Setup Configuration Documentation]] | ||
==Details== | ==Details== | ||
Line 58: | Line 110: | ||
*Second, it measures performance characteristics while it's running the pageload tests--you can track cpu speed, memory, or any of the other counters listed [http://technet2.microsoft.com/WindowsServer/en/Library/86b5d116-6fb3-427b-af8c-9077162125fe1033.mspx?mfr=true here]. | *Second, it measures performance characteristics while it's running the pageload tests--you can track cpu speed, memory, or any of the other counters listed [http://technet2.microsoft.com/WindowsServer/en/Library/86b5d116-6fb3-427b-af8c-9077162125fe1033.mspx?mfr=true here]. | ||
+ | |||
==Web logs== | ==Web logs== | ||
*[http://weblogs.mozillazine.org/qa/ Mozilla Quality Assurance and Testing Blog for Mozilla Firefox and Thunderbird] | *[http://weblogs.mozillazine.org/qa/ Mozilla Quality Assurance and Testing Blog for Mozilla Firefox and Thunderbird] | ||
+ | *[http://wiki.mozilla.org/MozillaQualityAssurance:Performance_Testing Mozilla Quality Assurance Performance Testing] | ||
+ | |||
+ | ==Submission== | ||
+ | Still in progress!<br /> | ||
+ | While it's sizzling, try out the Firefox Performance Testing Framework (version 2) at [[New_Firefox_Performance_Testing_Documentation#Quick_start| New Firefox Performance Testing Documentation Quick Start section]] - 3 easy steps | ||
+ | <table style="width:100%;" border="1px" valign="top" class="standard-table" cellpadding=2 cellspacing=0> | ||
+ | <th style="width: 20%; background-color:#333333; color:#F3F3F3">Artifact</th> | ||
+ | <th style="width: 30%%; background-color:#333333; color:#F3F3F3">Details</th> | ||
+ | <th style="width: 20%; background-color:#333333; color:#F3F3F3">Links</th> | ||
+ | <tr> | ||
+ | <td valign="top">run_tests.py</td> | ||
+ | <td valign="top"> | ||
+ | *Python file used to execute the Firefox Performance Testing | ||
+ | *Some of the things it does: | ||
+ | ** Validates files and directories needed for Performance Testing | ||
+ | ** Displays informative messages to allow users to fix any invalidity in files or directories | ||
+ | ** Displays an informative progress/status bar that informs users how far into the testing they are | ||
+ | *Things that Alice and I discussed are reflected in this file: | ||
+ | ** Configuration checker | ||
+ | *** yaml file validator | ||
+ | *** paths.py validator | ||
+ | **** checking the paths for existance | ||
+ | ***** notify user if path doesnt exist and ask user if they want it created | ||
+ | **** checking if the directories have contents | ||
+ | |||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[run_tests.py]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">perfconfig.sh</td> | ||
+ | <td valign="top">This script is used to automate the tedious Firefox Performance Testing Configuration | ||
+ | *Main Contributor | ||
+ | ** [[User:dwwoodsi|Dean Woodside]] (dean) | ||
+ | *With this script: | ||
+ | ** Configuration of python framework is eased | ||
+ | |||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[perfconfig.sh]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Progress bar class</td> | ||
+ | <td valign="top"> | ||
+ | *Modified open source code to be used for this project | ||
+ | *Displays a progress/status bar so users will know at which stage of the Performance Testing they are at (by percentage%, sort of) | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[pb.py]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">paths.py</td> | ||
+ | <td valign="top"> | ||
+ | *This is the file that contains all the paths that are needed for the Performance Testing | ||
+ | *Fixed the paths and modified some documentation</td> | ||
+ | <td valign="top"> | ||
+ | [[paths.py]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Firefox Performance Testing Documentation (Version 1)</td> | ||
+ | <td valign="top"> | ||
+ | *This was the first documentation that was written to improve the documentation provided in the initial | ||
+ | Firefox Performance Testing Framework (Refer to [[Readme.txt]]) | ||
+ | *It was deemed to be too elaborative and needed to be more concise | ||
+ | *Needed work | ||
+ | *Users didn't like the configuration steps they had to take | ||
+ | ** For more ranting:[[#Comments_on_the_Firefox_Performance_Testing_Framework | DPS909 Student comments]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows_Documentation | Performance Testing Setup Configuration Documentation]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Firefox Performance Testing Documentation (Version 2)</td> | ||
+ | <td valign="top"> | ||
+ | *<b>To try Firefox Performance Testing out, go to this documentation</b> | ||
+ | *This the new documentation that is improved with the [[#Comments_on_the_Firefox_Performance_Testing_Framework | student comments]] | ||
+ | *Building a user base.. some comments on this NEW framework | ||
+ | **[[New Firefox Performance Testing Framework comments]] | ||
+ | |||
+ | <b>Goals achieved:</b> | ||
+ | * Effective | ||
+ | **Easy-to-use | ||
+ | **Free from confusion | ||
+ | **Informative and helpful | ||
+ | *Efficient | ||
+ | **Takes almost no time to set up the framework | ||
+ | **Captures <b>most</b> user errors through validation and saves user time and frustration to fix an error while running the framework | ||
+ | ***Informs user of the directory/file invalidity or if they ran an invalid config file etc. | ||
+ | |||
+ | Additional: | ||
+ | *Users don't have to know the whole framework to configure it | ||
+ | ** Documentation helps | ||
+ | *Users are not left staring at the console wondering what is happening when they run the Performance Tests | ||
+ | ** Progress bar and informative messages | ||
+ | *Users don't have to waste hours/days/weeks debugging the code to find out why they are having problems configuring the framework | ||
+ | ** I spent 2 weeks configuring the <strike>bloody</strike> framework | ||
+ | |||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[New_Firefox_Performance_Testing_Documentation | New Firefox Performance Testing Documentation]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | |||
+ | <tr> | ||
+ | <td valign="top">Status Documentation</td> | ||
+ | <td valign="top"> | ||
+ | *Here are the progress charts for this project | ||
+ | *They are divided into 3: | ||
+ | ** Performance Testing Framework First Version | ||
+ | ** Performance Testing Framework Second Version | ||
+ | ** More details of things to fix for the framework | ||
+ | |||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *[[Things to fix for Performance Testing Framework | More details of things to fix for Performance Testing Framework]] | ||
+ | *[[#Extended_Progress_Chart_.28Version_2.29 | Version 2]] | ||
+ | *[[#Progress_.28Version_1.29 | Version 1]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top"> | ||
+ | Firefox Performance Testing Framework Directory Structure | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *Here is an overview of the Firefox Performance Testing Framework Directory Structure. | ||
+ | *The directory structure is revised | ||
+ | *There were too many extra libraries to load which caused too many dependencies | ||
+ | *Directory structure was difficult to keep track due to redundant directories and extra libraries | ||
+ | *All configuration is in one place! | ||
+ | ** config.yaml | ||
+ | ** paths.py | ||
+ | ** constants | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[#Directory_Structure_of_Framework| Performance Testing Framework Directory Structure]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top"> | ||
+ | Screen shots | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *Here is a screen shot of the program when it is doing a performance testing: | ||
+ | |||
+ | [[Image:Perftesting running.png | Firefox Performance Testing running]] | ||
+ | |||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | Not Applicable | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top"> | ||
+ | Next Steps | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *Am I done? Not quite | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[#Next_Steps | Next Big Steps]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top"> | ||
+ | Reflections | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *Some thoughts | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | [[#Reflections_on_the_project | Reflections]] | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | ==Next Steps== | ||
+ | <table style="width:100%;" border="1px" valign="top" class="standard-table" cellpadding=2 cellspacing=0> | ||
+ | <th style="width: 15%; background-color:#333333; color:#F3F3F3">Task</th> | ||
+ | <th style="width: 30%; background-color:#333333; color:#F3F3F3">Details</th> | ||
+ | <th style="width: 10%; background-color:#333333; color:#F3F3F3">Priority</th> | ||
+ | <th style="width: 15%; background-color:#333333; color:#F3F3F3">Contributors</th> | ||
+ | <th style="width: 20%; background-color:#333333; color:#F3F3F3">Status</th> | ||
+ | <tr> | ||
+ | <td valign="top">Porting framework to other OSes</td> | ||
+ | <td valign="top"> | ||
+ | * <b>What good is a performance testing framework if it only runs on Windows??</b> | ||
+ | * This has been a pending task for awhile. | ||
+ | * Since several students made a point that it should port to other OSes, I should look into that | ||
+ | * Students who use OS X, Unix Oses etc. couldn't test this framework | ||
+ | </td> | ||
+ | <td style="background-color: #990000; text-align: center; font-weight: bold; color: #ffffff;" valign="top">High</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | |||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">0% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Run both ts and tp at the same time</td> | ||
+ | <td valign="top"> | ||
+ | *Will have a discussion with Alice Nodelman in regards to this | ||
+ | </td> | ||
+ | |||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">0% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | |||
+ | <tr> | ||
+ | <td valign="top">Create and execute new tests</td> | ||
+ | <td valign="top"> | ||
+ | *New test case(s) for performance | ||
+ | *Will have a discussion with Alice Nodelman in regards to this | ||
+ | </td> | ||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">0% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | |||
+ | </table> | ||
+ | |||
+ | ==Extended Progress Chart (Version 2)== | ||
+ | <table style="width:100%;" border="1px" valign="top" class="standard-table" cellpadding=2 cellspacing=0> | ||
+ | <th style="width: 15%; background-color:#333333; color:#F3F3F3">Task</th> | ||
+ | <th style="width: 30%; background-color:#333333; color:#F3F3F3">Details</th> | ||
+ | <th style="width: 10%; background-color:#333333; color:#F3F3F3">Priority</th> | ||
+ | <th style="width: 15%; background-color:#333333; color:#F3F3F3">Contributors</th> | ||
+ | <th style="width: 20%; background-color:#333333; color:#F3F3F3">Status</th> | ||
+ | <tr> | ||
+ | <td valign="top">Read all student comments about framework and improve it</td> | ||
+ | <td valign="top"> | ||
+ | * On Nov 29th, students of DPS909 contributed by testing the framework | ||
+ | * They have listed constructive feedback and many great suggestions to help improve the setup of the framework | ||
+ | ** [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | Student comments about framework]] | ||
+ | </td> | ||
+ | <td style="background-color: #990000; text-align: center; font-weight: bold; color: #ffffff;" valign="top">High</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | * I've read some comments but I need some time to drill down ones that will help to improve the framework. | ||
+ | * Nevertheless, all the comments are really REALLY helpful to facilitate in improving this framework. | ||
+ | |||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">100% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Drill and narrow down the student comments to improve framework</td> | ||
+ | <td valign="top"> | ||
+ | *Improve framework as per suggested by the students: [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | Student comments about framework]] | ||
+ | *Only pick the important ones | ||
+ | *[[Things to fix for Performance Testing Framework | More details]] | ||
+ | </td> | ||
+ | <td style="background-color: #990000; text-align: center; font-weight: bold; color: #ffffff;" valign="top">High</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | * Working on some of the comments that helps make the framework stronger and more robust | ||
+ | * Some tasks might be redundant. Nonetheless, I'm clear about what should be fixed | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">In progress</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Fix [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows_Documentation | Performance Testing Setup Configuration Documentation]] and framework configuration</td> | ||
+ | <td valign="top"> | ||
+ | * From the [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | student comments about the framework]], I have gathered that the documentation have to be fixed as some parts are vague and some important areas are not highlighted. | ||
+ | * Some Items ([[Things to fix for Performance Testing Framework | More details]]): | ||
+ | ** Make the ''Create extension_perf_reports directory''' part bold | ||
+ | *** Maybe ask the user if they want it to be generated if it doesn't exist (will be done in framework) | ||
+ | *** Should it be created from the sh script?? | ||
+ | ** '''config.yaml''' file | ||
+ | *** If user chooses to test with no preferences or extensions, should mention about commenting the lines beneath them. | ||
+ | ** Additional details regarding Framework Prerequisites would reduce confusion. | ||
+ | *** Comment from student: There isn't any harm in "dumbing it down" a level. | ||
+ | |||
+ | *[[Things to fix for Performance Testing Framework | More details]] | ||
+ | |||
+ | </td> | ||
+ | <td style="background-color: #990000; text-align: center; font-weight: bold; color: #ffffff;" valign="top">High</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | <b>New status</b> | ||
+ | |||
+ | [[New Firefox Performance Testing Documentation]] | ||
+ | |||
+ | |||
+ | <b>Older status</b> | ||
+ | |||
+ | Will start on this after drilling down the [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | student comments]] | ||
+ | |||
+ | |||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">In progress</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Pre-requisites: Python, Cywin and .dll Installation Guidelines</td> | ||
+ | <td valign="top"> | ||
+ | * Order of installations | ||
+ | * Cygwin | ||
+ | **Students were confused as to whether they should keep the default [http://www.cygwin.com/setup.exe Cygwin] setup/packages as the documentation didn't outline that. | ||
+ | **They inquired which Cygwin packages are required | ||
+ | * Concerns about where the .[http://www.driverskit.com/dll/msvcp71.dll/2371.html msvcp71.dll] file should be installed after it's downloaded | ||
+ | * A few students got the error: ImportError: No module named win32pdh | ||
+ | ** missed out install the Python Win32 Extensions - sh script handles it now | ||
+ | * Now that the sh script handles the pre-requisite installation, are the following necessary? | ||
+ | ** Some files seem to have dependencies on another. Need to point whether some files have to be installed in order. | ||
+ | ** Some files have the same installation GUI, which makes it hard to track down which have been installed and which have not. Some screenshots may help. | ||
+ | ** For '''Cygwin''' installation, should note that default package setting is sufficient. Remove all doubts. | ||
+ | </td> | ||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | *All these issues are mitigated by the [[perfconfig.sh]] script. | ||
+ | *This script automates all the tedious steps you have to go through to run your performance testing which was, unfortunately, loathed by users. (Based on [[#Comments_on_the_Firefox_Performance_Testing_Framework | student comments]]) | ||
+ | *See it for yourself! Try it out: [[New_Firefox_Performance_Testing_Documentation#Quick_start| New Firefox Performance Testing Documentation Quick Start section]] | ||
+ | *I'm also gathering user feedback: | ||
+ | [[New Firefox Performance Testing Framework comments]] | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">100% done</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td valign="top">Configuring Environment Specifications in documentation</td> | ||
+ | <td valign="top"> | ||
+ | <b>BASE_PROFILE_DIR</b> | ||
+ | * No instructions on what exactly to place in the Hostperm.1 file. | ||
+ | * Hostperm.1 file is autogenerated and warns against editing it. | ||
+ | * Mention how to modify the Hostperm.1 file. | ||
+ | </td> | ||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | I have nothing to work with besides the [[Readme.txt | README.TXT]] file by Annie Sullivan. Therefore, I have to consult Alice Nodelman in this area. | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">In progress</div> | ||
+ | </td> | ||
+ | </tr> | ||
− | ==Progress== | + | <tr> |
+ | <td valign="top">Automate environment configuration</td> | ||
+ | <td valign="top"> | ||
+ | |||
+ | *One of the [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | student comments]] is to write a bat/sh file to automate the configurations of the pre-requisites for the framework | ||
+ | </td> | ||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:dwwoodsi|Dean Woodside]] (dean) | ||
+ | ** Submitted sh script | ||
+ | * [[User:djhamp-g | David Hamp-Gonsalves]] (inveigle) | ||
+ | ** Looked into this, gave pointers | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | * [[User:dwwoodsi|Dean Woodside]] has submitted a sh scripting for this. It works great. Needs to be touched up | ||
+ | **[http://www.yorku.ca/abel/liz/mozilla/perfconfig.zip Sh script zip] | ||
+ | |||
+ | * [[User:elichak |Liz Chak]] will fix up the sh script | ||
+ | **Doesn't make a reports folder (should this be in the sh script??) | ||
+ | **Still runs the whole script even if it couldn't download the pre-requisites, should terminate | ||
+ | **Missed out the paths.py file | ||
+ | **Requires touch ups, but everything else is good | ||
+ | **Proper documentation | ||
+ | |||
+ | Files: | ||
+ | *[[perfconfig.sh]] - Source code | ||
+ | *[http://www.yorku.ca/abel/liz/mozilla/perfconfig.sh Actual Script to configure Firefox Performance Testing Framework] | ||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">100% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | |||
+ | <tr> | ||
+ | <td valign="top">Porting framework to other OSes</td> | ||
+ | <td valign="top"> | ||
+ | * This has been a pending task for awhile. | ||
+ | * Since several students made a point that it should port to other OSes, I should look into that | ||
+ | * Students who use OS X, Unix Oses etc. couldn't test this framework | ||
+ | </td> | ||
+ | <td style="background-color: #E9DA73; text-align: center; font-weight: bold; color: #333333;" valign="top">Medium</td> | ||
+ | <td valign="top"> | ||
+ | * [[User:elichak|Liz Chak]] | ||
+ | </td> | ||
+ | <td valign="top"> | ||
+ | |||
+ | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">0% completed</div> | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | ==Progress (Version 1)== | ||
<table style="width:100%;" border="1px" valign="top" class="standard-table" cellpadding=2 cellspacing=0> | <table style="width:100%;" border="1px" valign="top" class="standard-table" cellpadding=2 cellspacing=0> | ||
Line 81: | Line 540: | ||
</td> | </td> | ||
<td valign="top"> | <td valign="top"> | ||
+ | <b>Newer status</b> | ||
+ | The DPS909 class tested the documentation and framework out. | ||
+ | *Needed rework | ||
+ | |||
+ | <b>Older status</b> | ||
*Improving the current documentation so that it's easier to follow | *Improving the current documentation so that it's easier to follow | ||
*Making sure that all the configuration documents are in one place | *Making sure that all the configuration documents are in one place | ||
*This is done along with the code base work I'm doing | *This is done along with the code base work I'm doing | ||
− | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;"> | + | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">100% completed</div> |
</td> | </td> | ||
</tr> | </tr> | ||
Line 167: | Line 631: | ||
− | <div style="width:100%;background-color:#F3F3F3"> | + | <div style="width:100%;background-color:#F3F3F3">100% completed (Alice reviewed)</div> |
</td> | </td> | ||
</tr> | </tr> | ||
Line 217: | Line 681: | ||
** Checks if base_profile contents exist! | ** Checks if base_profile contents exist! | ||
** Got some suggestions from [[User:Robcee | Rob Campbell]], going to work with his suggestions | ** Got some suggestions from [[User:Robcee | Rob Campbell]], going to work with his suggestions | ||
− | + | ** Checks file urls | |
*Things left to do | *Things left to do | ||
** Check if base_profile contents exist - DONE | ** Check if base_profile contents exist - DONE | ||
*** Alice adviced that I should check contents in general - no specific files or directories because they can change depending on what the developer is testing | *** Alice adviced that I should check contents in general - no specific files or directories because they can change depending on what the developer is testing | ||
− | ** Check files in (file:///c:/) format | + | ** Check files in (file:///c:/) format - DONE |
*** create a temporary variable for the local pathname, convert the path to the os path and then check | *** create a temporary variable for the local pathname, convert the path to the os path and then check | ||
*** split and join | *** split and join | ||
*** urlparse | *** urlparse | ||
− | ** Work on checking Cygwin paths | + | ** Work on checking Cygwin paths |
*** split and join | *** split and join | ||
Line 261: | Line 725: | ||
*I have fixed the program to check for the existence of the base_profile dir and it also checks if the bookmarkbackups, Cache dirs and perf.js dir exist. | *I have fixed the program to check for the existence of the base_profile dir and it also checks if the bookmarkbackups, Cache dirs and perf.js dir exist. | ||
− | <div style="width:100%;background-color:#F3F3F3"> | + | <div style="width:100%;background-color:#F3F3F3">100% completed</div> |
</td> | </td> | ||
Line 283: | Line 747: | ||
− | + | 100% completed - needs to be reviewed</div> | |
</td> | </td> | ||
</tr> | </tr> | ||
Line 309: | Line 773: | ||
<td valign="top"> | <td valign="top"> | ||
* [[User:elichak|Liz Chak]] | * [[User:elichak|Liz Chak]] | ||
− | * [[User:eor | Eva Or]] | + | * [[User:eor | Eva Or]] & [[User:mylau | Mike Lau]] |
− | ** | + | * [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#In-Class_Contributors|Whole class]]! |
+ | ** Setup framework using the new documentation - Things to look out for: If it's user-oriented and if it is easy to setup | ||
+ | ** Gave constructive feedback on documentation | ||
</td> | </td> | ||
<td valign="top"> | <td valign="top"> | ||
− | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;"> | + | <div style="width:100%;background-color:#F3F3F3;position:relative;margin-bottom:0px;">100% completed</div> |
</td> | </td> | ||
</tr> | </tr> | ||
</table> | </table> | ||
− | ==Comments on the | + | ==Comments on the [[Readme.txt | README.TXT]] Documentation (By Mike Lau)== |
'''Getting Started''' | '''Getting Started''' | ||
Line 351: | Line 817: | ||
==Solution: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs== | ==Solution: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs== | ||
− | In paths.py, the paths for INIT_URL, TS_URL and TP_URL have to be | + | In paths.py, the paths for INIT_URL, TS_URL and TP_URL have to be a local file url, not file path (file:///c:/): |
<pre> | <pre> | ||
"""The path to the file url to load when initializing a new profile""" | """The path to the file url to load when initializing a new profile""" | ||
Line 382: | Line 848: | ||
* By default in paths.py: BASE_PROFILE_DIR = r'C:\extension_perf_testing\base_profile' | * By default in paths.py: BASE_PROFILE_DIR = r'C:\extension_perf_testing\base_profile' | ||
* The BASE_PROFILE_DIR could be a different path, it doesn't have to be like the one above. | * The BASE_PROFILE_DIR could be a different path, it doesn't have to be like the one above. | ||
+ | |||
+ | ==Problem: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config== | ||
+ | *You have to change the dom.allow_scripts_to_close_windows preference to true | ||
+ | |||
+ | ==Solution: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config== | ||
+ | *Type in about:config in the address bar | ||
+ | *Scroll down and look for dom.allow_scripts_to_close_windows | ||
+ | *Double click on it to set it to true | ||
+ | |||
+ | =Directory Structure of Framework= | ||
+ | |||
+ | |||
+ | ==Overview of Structure== | ||
+ | A glance at the Framework File Structure (CVS files not included): | ||
+ | |||
+ | <pre> | ||
+ | win32 | ||
+ | | | ||
+ | | | ||
+ | |__ base_profile (dir) | ||
+ | | | | ||
+ | | |__ bookmarkbackups (dir) | ||
+ | | | | | ||
+ | | | |__ .html files | ||
+ | | | | ||
+ | | |__ Cache (dir) | ||
+ | | | | ||
+ | | |__ .bak, .html, .ini, .dat, .txt, .js, .rdf, .mfl files | ||
+ | | | ||
+ | | | ||
+ | |__ page_load_test(dir) | ||
+ | | | | ||
+ | | |__ base(dir) | ||
+ | | | | | ||
+ | | | |__ other dirs and .html files | ||
+ | | | | ||
+ | | |__ cycler.html & report.html | ||
+ | | | ||
+ | | | ||
+ | |__ startup_test | ||
+ | | | | ||
+ | | |__ startup_test.html | ||
+ | | | ||
+ | | | ||
+ | |__ extension_perf_reports (dir for generated reports) | ||
+ | | | ||
+ | | | ||
+ | |__ run_tests.py, paths.py, config.yaml and other .py, .html files | ||
+ | |||
+ | </pre> | ||
+ | |||
+ | *NOTE: Content in '''base_profile''' dir may vary | ||
+ | |||
+ | |||
+ | The following is written by Annie Sullivan (annie.sullivan@gmail.com): | ||
+ | |||
+ | ==base_profile/== | ||
+ | *This directory contains the base profile used for testing. | ||
+ | *A copy of this profile is made for each testing profile, and extensions or prefs are added according to the test_configs array in run_tests.py. | ||
+ | *For the page load test to run correctly, the hostperm.1 file must be set to allow scheme:file uris to open in new windows, and the pref to force a window to open in a tab must not be set. | ||
+ | *The dom.allow_scripts_to_close_windows pref should also be set to true. The browser.shell.checkDefaultBrowser pref should be set to false. | ||
+ | |||
+ | |||
+ | ==page_load_test/== | ||
+ | *This directory contains the JavaScript files and html data files for the page load test. | ||
+ | *The page load test opens a new window and cycles through loading each html file, timing each load. | ||
+ | |||
+ | |||
+ | ==startup_test/== | ||
+ | *This directory contains the JavaScript to run the startup test. | ||
+ | *It measures how long it takes Firefox to start up. | ||
+ | |||
+ | |||
+ | ==extension_perf_report/== | ||
+ | *This directory is where the generated report will go into. | ||
+ | *You may specify another directory to substitute this directory, but make sure that the '''paths.py''' is changed to point to it. | ||
+ | |||
+ | |||
+ | ==run_tests.py, paths.py== | ||
+ | *These files should be configured to run the test on different machines, with different extensions or preferences. See setup above. | ||
+ | |||
= Project News = | = Project News = | ||
Line 503: | Line 1,050: | ||
==Tuesday, 21 Nov 2006== | ==Tuesday, 21 Nov 2006== | ||
Refer to progress chart. | Refer to progress chart. | ||
− | [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows# | + | [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Progress_.28Version_1.29| Performance Testing Framework progress chart]] |
− | + | ||
+ | ==Wednesday, 29 Nov 2006== | ||
+ | In-class Performance Testing Framework Configuration | ||
+ | * DPS909 students contributed by testing the framework | ||
+ | * Students have listed constructive feedback and many great suggestions to help improve the setup of the framework | ||
+ | ** [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Comments_on_the_Firefox_Performance_Testing_Framework | Student comments about framework]] | ||
+ | |||
+ | ==Sunday, 3 Dec 2006== | ||
+ | * [[User:dwwoodsi|Dean Woodside]] has submitted a sh scripting for this. It works great. Needs to be touched up. | ||
+ | **[http://www.yorku.ca/abel/mozilla/perfconfig.zip Sh script zip] | ||
+ | |||
+ | * [[User:elichak |Liz Chak]] will fix up the sh script | ||
+ | **Doesn't make a reports folder | ||
+ | **Still runs the whole script even if it couldn't download the pre-requisites, should terminate | ||
+ | **Missed out the paths.py file | ||
+ | **Requires touch ups, but everything else is good | ||
+ | |||
+ | ==Sunday, 10 Dec 2006== | ||
+ | * Narrowing down the things that need to be done before 13 December 2006 | ||
+ | * Refer to [[#Extended_Progress_Chart_.28Version_2.29 | Extended Progress Chart]] | ||
+ | |||
+ | ==Wednesday, 13 Dec 2006== | ||
+ | * Created a [[New_Firefox_Performance_Testing_Documentation | new documentation]] | ||
+ | * Finished my parts for the Performance Testing Framework | ||
+ | ** Refer to [[Firefox_Performance_Testing_:_A_Python_framework_for_Windows#Submission | submission]] | ||
+ | |||
+ | The current Firefox Performance Testing Framework is effective and efficient. | ||
+ | *<b>To try Firefox Performance Testing out, go to this documentation</b> | ||
+ | *This the new documentation that is improved with the [[#Comments_on_the_Firefox_Performance_Testing_Framework | student comments]] | ||
+ | *Building a user base.. some comments on this NEW framework | ||
+ | **[[New Firefox Performance Testing Framework comments]] | ||
+ | |||
+ | <b>Goals achieved:</b> | ||
+ | * Effective | ||
+ | **Easy-to-use | ||
+ | **Free from confusion | ||
+ | **Informative and helpful | ||
+ | *Efficient | ||
+ | **Takes almost no time to set up the framework | ||
+ | **Captures <b>most</b> user errors through validation and saves user time and frustration to fix an error while running the framework | ||
+ | ***Informs user of the directory/file invalidity or if they ran an invalid config file etc. | ||
+ | |||
+ | Things To-do (Immediately) | ||
+ | *Clean up this page - almost done | ||
+ | *Document source - almost done | ||
+ | *Fix up the [[New_Firefox_Performance_Testing_Documentation | Performance Testing Documentation]] | ||
+ | |||
=Project References= | =Project References= | ||
*I recommend these sites to learn about python: | *I recommend these sites to learn about python: | ||
Line 511: | Line 1,104: | ||
= Project Events = | = Project Events = | ||
− | ==In class Firefox Performance Testing | + | ==In class Firefox Performance Testing== |
'''Before you begin''' | '''Before you begin''' | ||
# You have to be on a Windows operating system | # You have to be on a Windows operating system | ||
Line 530: | Line 1,123: | ||
'''List of comments:''' | '''List of comments:''' | ||
+ | |||
+ | * [[Mark D'Souza perf comments]] | ||
+ | * [[Sherman Fernandes perf comments]] | ||
+ | * [[Aditya Nanda Kuswanto perf comments]] | ||
+ | * [[Richard Chu perf comments]] | ||
+ | * [[David Manley perf comments]] | ||
+ | * [[Djhamp-g perf comments]] | ||
+ | * [[Colin Guy perf comments]] | ||
+ | * [[Mohamed Attar perf comments]] | ||
+ | * [[Man Choi Kwan perf comments]] | ||
+ | * [[Mark Paruzel pref comments]] | ||
+ | * [[Jeff Mossop perf comments]] | ||
+ | * [[Melissa Peh perf comments]] | ||
+ | * [[Paul Yanchun Gu comments]] | ||
+ | * [[Vanessa Miranda comments]] | ||
+ | * [[Philip Vitorino perf comments]] | ||
+ | * [[Paul St-Denis Moe Bagheri perf comments]] | ||
+ | * [[Cesar Oliveira perf comments]] | ||
+ | * [[Firefox Performance Testing : A Python framework for Windows:Comments/Ben Hearsum|Ben Hearsum]] | ||
+ | * [[Themystic_perf_comments| Tom Aratyn]] | ||
+ | * [[davey_girl_comments| Erin Davey]] | ||
+ | * [[dwwoodsi perf comments| Dean Woodside]] | ||
+ | |||
+ | ==Reflections on the project== | ||
+ | Now that the first phase of the project is done, I would like to sit back and reflect on some of the experiences I have had with this project. Not only did this project grow, I have been growing with it. I've learned endless amount of things by working on this project (not just technical stuff). And as the saying goes, "you only learn from experience"! | ||
+ | |||
+ | ===Configuration frustration=== | ||
+ | Words can't express how I was initially frustrated with the framework. I hit brick walls a countless number of times when I tried to set the framework up and running and I was on the verge of giving up. It was only through my own perseverance and determination that I got this to work. | ||
+ | |||
+ | Outcome: A list of things to fix on the framework to ease the configuration, strengthen the framework and better documentation!! | ||
+ | |||
+ | ===First deliverable=== | ||
+ | I asked the class to test my first deliverable. I had faith that my framework would bring delight to my testers, but I was proven otherwise. Even with the effort that I've put into my first deliverable, it still created a group of frustrated and agonized users. Many of them ranted on what could be improved on the framework, hence: | ||
+ | |||
+ | Outcome: A list of things to automate the framework and EASE THE CONFIGURATION | ||
+ | |||
+ | ===Final deliverable=== | ||
+ | I'm glad that my first tester was thrilled about my Performance Testing. There is nothing better than a happy user. What I've learned is that TESTING is the KEY to a successful application. Why do so many of us developers neglect that?? | ||
+ | |||
+ | ===Credits=== | ||
+ | [[User:dwwoodsi|Dean Woodside]], Alice Nodelman, [[User:Bhearsum | Ben Hearsum]], [[User:Mylau | Michael Lau]], [[User:Eor | Eva Or]], [[User:djhamp-g | David Hamp Gonsalves ]], [[User:David.humphrey|Dave Humphrey]], [[User:robcee|Rob Campbell]] and of course, the DPS909 class who tested my framework. These are the individuals who played a significant part in making this framework headed toward success! | ||
==Bon Echo Community Test Day== | ==Bon Echo Community Test Day== |
Latest revision as of 14:22, 17 April 2013
Contents
- 1 Project Name
- 2 Project Description
- 3 Project Leader(s)
- 4 Project Contributor(s)
- 5 Project Details
- 6 Project Problems and Solutions
- 6.1 Problem: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs
- 6.2 Solution: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs
- 6.3 Problem: ZeroDivisionError: integer division or modulo by zero
- 6.4 Solution: ZeroDivisionError: integer division or modulo by zero
- 6.5 Problem: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config
- 6.6 Solution: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config
- 7 Directory Structure of Framework
- 8 Project News
- 8.1 Saturday, September 23, 2006
- 8.2 Sunday, September 24, 2006
- 8.3 Monday, September 25, 2006
- 8.4 Friday, September 29, 2006
- 8.5 Sunday, October 1, 2006
- 8.6 Wednesday, October 4, 2006
- 8.7 Friday, October 6, 2006
- 8.8 Wednesday, October 11, 2006
- 8.9 Thusday, October 12, 2006
- 8.10 Friday, 20 Oct 2006
- 8.11 Tuesday, 31 Oct 2006
- 8.12 Tuesday, 21 Nov 2006
- 8.13 Wednesday, 29 Nov 2006
- 8.14 Sunday, 3 Dec 2006
- 8.15 Sunday, 10 Dec 2006
- 8.16 Wednesday, 13 Dec 2006
- 9 Project References
- 10 Project Events
Project Name
Firefox Performance Testing : A Python framework for Windows
Project Description
The goal of this project is to:
- get the current framework up and running to help work with others
- get the framework running in an automated fashion
- help with the creation and execution of new tests
- work to upgrade the framework to work with a mozilla graph server
- work with the mozilla community and contribute to an open source project
From this project, you will:
- learn python
- learn about white box testing methodologies
- work with an open source community
- more generally learn about the functioning of QA in an open source community
This will benefit you in the future when presented with a new program, you'll be able to give an idea of how to approach testing - to give adequate coverage and be able to provide some metric of program stability and functionality
Note: This is NOT the typical mundane black box testing
Project Leader(s)
Project Contributor(s)
Dean Woodside (dean)
- Submitted an sh file that automates the tedious performance testing framework configuration
Alice Nodelman
- Discussed on the things that need to be fixed to improve and strengthen the framework
- Gave suggestions on the new Performance Testing framework
Ben Hearsum (bhearsum)
- Set up the VM for performance testing
- Helped get me started with the debugging process for report.py, run_tests.py and ts.py
Michael Lau (mylau)
- Added comments on the documentation for setting up Performance Testing framework for Windows
- Tested the new and improved Performance Testing framework (version 1)
- Gave constructive feedback on documentation (version 1)
Eva Or (eor)
- Tested the new and improved Performance Testing framework (version 1)
- Gave constructive feedback on new documentation (version 1)
David Hamp Gonsalves (inveigle)
- Gave pointers on flushing buffer
- Helped with some grammar and sentence structuring for documentation (version 1)
- Tested and gave constructive feedback on the framework (version 1)
- Looked into a batch file for automating configuration, gave pointers
- Tested and commented on the new framework (version 2)
Rob Campbell (robcee)
- Gave me a number of python tips :)
Tom Aratyn (mystic)
- Introduced Closures in Python
In-Class Contributors
Please let me know if I missed you out. I've only listed the people whom I've received comments from. Those of you who participated but isn't listed as an in-class contributor, please list your comments here
- Mark D'Souza (mdsouza)
- Sherman Fernandes (sjfern)
- Aditya Nanda Kuswanto (vipers101)
- Dave Manley (seneManley)
- Colin Guy (Guiness)
- Mohamed Attar (mojo)
- Man Choi Kwan (mckwan)
- Mark Paruzel (RealMarkP or FakeMarkP)
- Jeff Mossop (JBmossop)
- Melissa Peh (melz)
- Paul Yanchun Gu (gpaul)
- Vanessa Miranda (vanessa)
- Philip Vitorino (philly)
- Paul St-Denis (pstdenis)
- Mohammad Tirtashi (moe)
- Cesar Oliveira (cesar)
- Andrew Smith (andrew)
- Ben Hearsum (bhearsum)
- Erin Davey (davey_girl)
- Tom Aratyn (mystic)
- David Hamp
- Dean Woodside (dean)
Project Details
Improved Documentation
Latest
New Firefox Performance Testing Documentation
First Attempt
Performance Testing Setup Configuration Documentation
Details
This is different from Tinderbox. Two major differences are:
- First, it doesn't build, it just runs the performance test given a path to the executable. This is helpful if you're testing the performance of an extension or a build from another server. (You could build on a fast server, and then run performance tests on a machine with low memory).
- Second, it measures performance characteristics while it's running the pageload tests--you can track cpu speed, memory, or any of the other counters listed here.
Web logs
- Mozilla Quality Assurance and Testing Blog for Mozilla Firefox and Thunderbird
- Mozilla Quality Assurance Performance Testing
Submission
Still in progress!
While it's sizzling, try out the Firefox Performance Testing Framework (version 2) at New Firefox Performance Testing Documentation Quick Start section - 3 easy steps
Artifact | Details | Links |
---|---|---|
run_tests.py |
|
|
perfconfig.sh | This script is used to automate the tedious Firefox Performance Testing Configuration
|
|
Progress bar class |
|
|
paths.py |
|
|
Firefox Performance Testing Documentation (Version 1) |
Firefox Performance Testing Framework (Refer to Readme.txt)
|
|
Firefox Performance Testing Documentation (Version 2) |
Goals achieved:
Additional:
|
|
Status Documentation |
|
|
Firefox Performance Testing Framework Directory Structure |
|
|
Screen shots |
|
Not Applicable |
Next Steps |
|
|
Reflections |
|
Next Steps
Task | Details | Priority | Contributors | Status |
---|---|---|---|---|
Porting framework to other OSes |
|
High |
0% completed
|
|
Run both ts and tp at the same time |
|
Medium |
0% completed
|
|
Create and execute new tests |
|
Medium |
0% completed
|
Extended Progress Chart (Version 2)
Task | Details | Priority | Contributors | Status |
---|---|---|---|---|
Read all student comments about framework and improve it |
|
High |
100% completed
|
|
Drill and narrow down the student comments to improve framework |
|
High |
In progress
|
|
Fix Performance Testing Setup Configuration Documentation and framework configuration |
|
High |
New status New Firefox Performance Testing Documentation
Will start on this after drilling down the student comments
In progress
|
|
Pre-requisites: Python, Cywin and .dll Installation Guidelines |
|
Medium |
New Firefox Performance Testing Framework comments 100% done
|
|
Configuring Environment Specifications in documentation |
BASE_PROFILE_DIR
|
Medium |
I have nothing to work with besides the README.TXT file by Annie Sullivan. Therefore, I have to consult Alice Nodelman in this area. In progress
|
|
Automate environment configuration |
|
Medium |
|
Files: 100% completed
|
Porting framework to other OSes |
|
Medium |
0% completed
|
Progress (Version 1)
Task | Details | Priority | Contributors | Status |
---|---|---|---|---|
Performance Testing Setup Configuration Documentation |
|
High |
Newer status The DPS909 class tested the documentation and framework out.
Older status
100% completed
|
|
Study performance testing framework |
The framework has to be strengthened and improved. A discussion with Alice Nodelman is planned to discuss about things that could be done to make the framework stronger. |
High |
|
Tested the framework and went through the coding in the framework. Made a list of the weaknesses of the framework and planned various resolutions.
We have established that the following has to be done:
100% completed
|
Configuration checker |
The configuration checker will check if all the configuration is done before running the performance testing. The checker is in run_tests.py and it entails:
This can only be done when the yaml file validator and paths.py validator are completed. |
High |
Started and ongoing
|
|
yaml file validator |
In run_tests.py: The validator of yaml file is weak. It only checks for certain items in the file and will crash if those items are not there or if those items doesn't have any value. It doesn't check for unexpected values and doesn't give the user a clue that their yaml file has a problem. |
High |
|
Changed the validator to check if items exist before storing the value. If one of the items doesn't exist, the program will terminate and it will let the user know that the yaml file has to be fixed. The yaml validator works in the following manner:
100% completed (Alice reviewed)
|
paths.py validator |
Currently the run_tests.py file doesn't validate the paths.py file. If the user misses a path or does a bad directory configuration, the program will crash and give this error: Traceback (most recent call last): File "C:\proj\mozilla\testing\ performance\win32\run_tests.py", line 129, in ? test_file(sys.argv[i]) File "C:\proj\mozilla\testing\ performance\win32\run_tests.py", line 122, in test_file TP_RESOLUTION) File "C:\proj\mozilla\testing\ performance\win32\report.py", line 152, in GenerateReport mean = mean / len(ts_times[i]) ZeroDivisionError: integer division or modulo by zero The following has to be done in the run_tests.py file to validate the paths.py file:
|
High |
|
Most updated progress
Older progress
extension_perf_testing(dir) | | base_profile (dir) | |__ bookmarkbackups (dir) | | | |__ .html files | |__ Cache (dir) | |__ .bak, .html, .ini, .dat, .txt, .rdf, .mfl files (most important file - perf.js)
100% completed
|
Get all the configuration in one place |
The framework is currently very confusing and the configuration is all over the place! This has to be fixed, but it's not the main priority:
As long as a good documentation is provided, this is not a main priority |
Medium |
Changed structure of directory
|
|
Setup and test out the current Performance Testing framework using the provided documentation (not mine) to discover more flaws in either the framework or documentation. This will facilitate me in using a more user-oriented approach when improving the framework and documentation |
More input is welcome on the current Performance Testing framework to help improve it. |
Medium |
on-going
|
|
Get class to test out the Performance Testing framework |
The improved framework has to be tested to get constructive feedback from the users using the new Performance Testing Setup Configuration Documentation |
Low |
|
100% completed
|
Comments on the README.TXT Documentation (By Mike Lau)
Getting Started
- I was not sure what to do after unzipping the win32.zip file.
Comments on The README.TXT File
- The README.TXT file is hard to read in notepad. There's horizontal scrolling after opening the file.
- The file should have output samples to show the user what output to expect and to ensure they are on the right track.
- The pre-requisites part of the README.TXT file is missing minimum size to be allocated in the computer to complete the install.
- Following the procedures for installation was difficult. The document should number the procedures and have sample outputs to ensure the user is going on the right track
- Some of the folders which was listed in the Directory Structure was missing in the setup procedures. The Directory Structure should be used as a guide to ensure users have the right folders in place. Also, there should be an image to represent the directory structure. Some of the folders which needed to be created on top of following the procedures provided were: base_profile, extension_perf_testing, extension_perf_reports
- The Setup part was hard to follow. Most of the steps were not intuitive.
- Step 4 of the procedures was unclear. I was not sure what kind of YAML config file to be created. The document should tell the user expcity what the file name needs to be called as or tell the user they can call it however they wish. It should also show an example filename as well.
Running The Application
After following the setup procedures, I typed the following command:
c:\> run_tests.py config.YAML
And I got the following error message in the command prompt and a popup window ( Liz Chak - Solution to this problem):
Project Problems and Solutions
Problem: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs
If you didn't configure the paths.py paths correctly, you may run into this problem when you run the Performance Testing Framework:
Solution: Firefox doesn't know how to open this address, because the protocol (c) isn't associated with any programs
In paths.py, the paths for INIT_URL, TS_URL and TP_URL have to be a local file url, not file path (file:///c:/):
"""The path to the file url to load when initializing a new profile""" INIT_URL = 'file:///c:/project/mozilla/testing/performance/win32/initialize.html' """The path to the file url to load for startup test (Ts)""" TS_URL = 'file:///c:/project/mozilla/testing/performance/win32/startup_test/startup_test.html?begin=' """The path to the file url to load for page load test (Tp)""" TP_URL = 'file:///c:/project/mozilla/testing/performance/win32/page_load_test/cycler.html'
Problem: ZeroDivisionError: integer division or modulo by zero
Traceback (most recent call last): File "C:\proj\mozilla\testing\performance\win32\run_tests.py", line 129, in ? test_file(sys.argv[i]) File "C:\proj\mozilla\testing\performance\win32\run_tests.py", line 122, in te st_file TP_RESOLUTION) File "C:\proj\mozilla\testing\performance\win32\report.py", line 152, in Gener ateReport mean = mean / len(ts_times[i]) ZeroDivisionError: integer division or modulo by zero
Solution: ZeroDivisionError: integer division or modulo by zero
Check if there is contents in the base_profile directory that you have set for BASE_PROFILE_DIR in paths.py:
- By default in paths.py: BASE_PROFILE_DIR = r'C:\extension_perf_testing\base_profile'
- The BASE_PROFILE_DIR could be a different path, it doesn't have to be like the one above.
Problem: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config
- You have to change the dom.allow_scripts_to_close_windows preference to true
Solution: This page should close Firefox. If it does not, please make sure that the dom.allow_scripts_to_close_windows preference is set to true in about:config
- Type in about:config in the address bar
- Scroll down and look for dom.allow_scripts_to_close_windows
- Double click on it to set it to true
Directory Structure of Framework
Overview of Structure
A glance at the Framework File Structure (CVS files not included):
win32 | | |__ base_profile (dir) | | | |__ bookmarkbackups (dir) | | | | | |__ .html files | | | |__ Cache (dir) | | | |__ .bak, .html, .ini, .dat, .txt, .js, .rdf, .mfl files | | |__ page_load_test(dir) | | | |__ base(dir) | | | | | |__ other dirs and .html files | | | |__ cycler.html & report.html | | |__ startup_test | | | |__ startup_test.html | | |__ extension_perf_reports (dir for generated reports) | | |__ run_tests.py, paths.py, config.yaml and other .py, .html files
- NOTE: Content in base_profile dir may vary
The following is written by Annie Sullivan (annie.sullivan@gmail.com):
base_profile/
- This directory contains the base profile used for testing.
- A copy of this profile is made for each testing profile, and extensions or prefs are added according to the test_configs array in run_tests.py.
- For the page load test to run correctly, the hostperm.1 file must be set to allow scheme:file uris to open in new windows, and the pref to force a window to open in a tab must not be set.
- The dom.allow_scripts_to_close_windows pref should also be set to true. The browser.shell.checkDefaultBrowser pref should be set to false.
page_load_test/
- This directory contains the JavaScript files and html data files for the page load test.
- The page load test opens a new window and cycles through loading each html file, timing each load.
startup_test/
- This directory contains the JavaScript to run the startup test.
- It measures how long it takes Firefox to start up.
extension_perf_report/
- This directory is where the generated report will go into.
- You may specify another directory to substitute this directory, but make sure that the paths.py is changed to point to it.
run_tests.py, paths.py
- These files should be configured to run the test on different machines, with different extensions or preferences. See setup above.
Project News
Saturday, September 23, 2006
Performance tests didn't run sucessfully.
- There weren't any results generated in the extension_perf_testing\base_profile and extension_perf_reports folders.
- Output after the performance tests were run:
Traceback (most recent call last): File "C:\proj\mozilla\testing\performance\win32\run_tests.py", line 129, in ? test_file(sys.argv[i]) File "C:\proj\mozilla\testing\performance\win32\run_tests.py", line 122, in te st_file TP_RESOLUTION) File "C:\proj\mozilla\testing\performance\win32\report.py", line 152, in Gener ateReport mean = mean / len(ts_times[i]) ZeroDivisionError: integer division or modulo by zero
Sunday, September 24, 2006
Understand further the approach to testing with the Python framework
Monday, September 25, 2006
elichak will be working on a resolution with alice to get the results generated in the extension_perf_testing\base_profile and extension_perf_reports folders.
Friday, September 29, 2006
elichak re-configured the environment of the machine to run the tests again. Cleaned up old files to do a clean test. Reinstalled Cygwin (replaced Make 3.80 with Make 3.81) and updated the testing files through CVS.
Sunday, October 1, 2006
Alice has successfully run the tests. The Zero Division error didn't occur again after she updated her test files. There were results generated in the extension_perf_testing\base_profile and extension_perf_reports folders. elichak attempted to run the test with the alice's code but the Zero Divsion Error still occured on her machine.
Wednesday, October 4, 2006
Elichak consulted Robcee about the Zero Division Error and he suggested a few things, like debugging the script. Elichak found out that the value of ts_time in the report.py file is empty but couldn't find out why the value of ts_time isn't assigned. According to alice, she didn't debug the scripts and only had to update the files to make them work.
Friday, October 6, 2006
Ben set up the VM for elichak to run her performance testing in that environment.
Wednesday, October 11, 2006
- elichak configured the environment in the VM for her testing. The tests still gave the same results as before:
- Zero Division Error at lines 122 and 129 in run_tests.py and line 153 in report.py
- 2 files in the extension_perf_reports dir are generated but there are no graphs
- elichak also changed the TS_NUM_RUNS, TP_NUM_CYCLES, TP_RESOLUTION values to 1 in run_tests.py to shorten the cycles of the performance testing for the purpose of debugging the scripts.
- The error occurs in report.py because ts_time is empty, therefore, this fails:
for ts_time in ts_times[i]: mean += float(ts_time) mean = mean / len(ts_times[i])
- Ben assisted elichak with the debugging process. elichak and Ben hacked deeper down into the scripts.
- We speculate that the thing that is affecting the value of ts_time being generated is in ffprocess.py: RunProcessAndWaitForOutput always returns None in line 232
return (None, True)
- Further debugging by elichak is in process
Thusday, October 12, 2006
Work completed
The Zero Division Error is solved. Turns out that it was just a configuration problem. The documentation to set up the environment was rather subtle and needs a re-work.
Solution
Contents in the C:\proj\mozilla\testing\performance\win32\base_profile should also be in C:\extension_perf_testing\base_profile dir.
All work for this project is done on the VM, hera.senecac.on.ca
Work in progress
- Trying out a few things in the framework to find out which direction I would like to do to the framework, either building new tests, improving on existing ones, strengthening the framework itself or porting it to other OS's
- Revise the Firefox Performance Testing documentation
Friday, 20 Oct 2006
Last week, elichak has established to work on automating the setup of the environment and performance testing. The performance testing and environment setup is currently all over the place and is tedious for the developer to set it up.
The automation will entail:
Generating directories, dropping files in directories, installation of libraries, options to configure the performance testings etc.
Tuesday, 31 Oct 2006
Alice and Liz had a meeting and have established the key things that need to be done. What needs to be done:
- ease configuration of python framework
- too many config files to edit
- have to know whole framework to configure it
- not flexible
- tedious
- too many directories to create
- too many extra libraries to load
- a lot of dependancies!
- things have to be copied to special directories
- bad configurations don't cause errors!
- too many config files to edit
How do we fix this?
- configuration checker
- yaml file validator
- paths.py validator
- checking the paths for existance
- notify user if path doesnt exist and ask user if they want it created
- checking if the directories have contents
- next steps
- get all the configuration in one place!
- paths.py, config.yml, constants
- have to run both ts and tp at the same time
- get all the configuration in one place!
Tuesday, 21 Nov 2006
Refer to progress chart. Performance Testing Framework progress chart
Wednesday, 29 Nov 2006
In-class Performance Testing Framework Configuration
- DPS909 students contributed by testing the framework
- Students have listed constructive feedback and many great suggestions to help improve the setup of the framework
Sunday, 3 Dec 2006
- Dean Woodside has submitted a sh scripting for this. It works great. Needs to be touched up.
- Liz Chak will fix up the sh script
- Doesn't make a reports folder
- Still runs the whole script even if it couldn't download the pre-requisites, should terminate
- Missed out the paths.py file
- Requires touch ups, but everything else is good
Sunday, 10 Dec 2006
- Narrowing down the things that need to be done before 13 December 2006
- Refer to Extended Progress Chart
Wednesday, 13 Dec 2006
- Created a new documentation
- Finished my parts for the Performance Testing Framework
- Refer to submission
The current Firefox Performance Testing Framework is effective and efficient.
- To try Firefox Performance Testing out, go to this documentation
- This the new documentation that is improved with the student comments
- Building a user base.. some comments on this NEW framework
Goals achieved:
- Effective
- Easy-to-use
- Free from confusion
- Informative and helpful
- Efficient
- Takes almost no time to set up the framework
- Captures most user errors through validation and saves user time and frustration to fix an error while running the framework
- Informs user of the directory/file invalidity or if they ran an invalid config file etc.
Things To-do (Immediately)
- Clean up this page - almost done
- Document source - almost done
- Fix up the Performance Testing Documentation
Project References
- I recommend these sites to learn about python:
Project Events
In class Firefox Performance Testing
Before you begin
- You have to be on a Windows operating system
- Take a deep breath and go through the Performance Testing Setup Configuration Documentation
- Make a page under Comments on the Firefox Performance Testing Framework (see below) to list out your comments on the framework
- The performance testing is only successful if you see generated results in the reports directory (you'll understand what this means once you start)
- Ask Liz Chak if you have any questions
Things to look out for
- If the documentation is easy to follow
- Did you stumble upon any difficulty? If so, state them
- List any system errors, if any (with the error message and a brief description of what you think caused it)
Comments on the Firefox Performance Testing Framework
Instructions:
- Make a page starting with your name/nick and end with "perf comments" (to ensure uniqueness)
- Example: Liz Chak perf comments
List of comments:
- Mark D'Souza perf comments
- Sherman Fernandes perf comments
- Aditya Nanda Kuswanto perf comments
- Richard Chu perf comments
- David Manley perf comments
- Djhamp-g perf comments
- Colin Guy perf comments
- Mohamed Attar perf comments
- Man Choi Kwan perf comments
- Mark Paruzel pref comments
- Jeff Mossop perf comments
- Melissa Peh perf comments
- Paul Yanchun Gu comments
- Vanessa Miranda comments
- Philip Vitorino perf comments
- Paul St-Denis Moe Bagheri perf comments
- Cesar Oliveira perf comments
- Ben Hearsum
- Tom Aratyn
- Erin Davey
- Dean Woodside
Reflections on the project
Now that the first phase of the project is done, I would like to sit back and reflect on some of the experiences I have had with this project. Not only did this project grow, I have been growing with it. I've learned endless amount of things by working on this project (not just technical stuff). And as the saying goes, "you only learn from experience"!
Configuration frustration
Words can't express how I was initially frustrated with the framework. I hit brick walls a countless number of times when I tried to set the framework up and running and I was on the verge of giving up. It was only through my own perseverance and determination that I got this to work.
Outcome: A list of things to fix on the framework to ease the configuration, strengthen the framework and better documentation!!
First deliverable
I asked the class to test my first deliverable. I had faith that my framework would bring delight to my testers, but I was proven otherwise. Even with the effort that I've put into my first deliverable, it still created a group of frustrated and agonized users. Many of them ranted on what could be improved on the framework, hence:
Outcome: A list of things to automate the framework and EASE THE CONFIGURATION
Final deliverable
I'm glad that my first tester was thrilled about my Performance Testing. There is nothing better than a happy user. What I've learned is that TESTING is the KEY to a successful application. Why do so many of us developers neglect that??
Credits
Dean Woodside, Alice Nodelman, Ben Hearsum, Michael Lau, Eva Or, David Hamp Gonsalves , Dave Humphrey, Rob Campbell and of course, the DPS909 class who tested my framework. These are the individuals who played a significant part in making this framework headed toward success!
Bon Echo Community Test Day
- Friday, October 06, 2006, from 7am - 5pm PDT