Private Browsing – Session Store Unit Tests – Milestone 0.2

Private Browsing – Session Store Unit Tests – Milestone 0.2

Session Store Unit Test(s) – Complete

Private Browsing aims to help you make sure that your web browsing activities don’t leave any trace on your own computer.  It is very important to note that Private Browsing is not a tool to keep you anonymous from websites or your ISP, or for example protect you from all kinds of spyware applications which use sophisticated techniques to intercept your online traffic.  Private Browsing is only about making sure that Firefox doesn’t store any data which can be used to trace your online activities, no more, no less.

In my second testing area, the act of not storing any data was meticulously reviewed.The second testing area, session store, is a second testing area I have focused on for my DPS909 project. The following is a visual representation of the testing that follows the testing plan I followed for the first unit test (A):

* The second unit may be found here, browser_248970_b.js alongside the sample test HTML file used may be found here

The following plan, follows the first unit test I wrote for session store, it is as follows (following the landed unit test: browser_248970_a.js)

  1. Open a tab (a)
  2. Remove the sessionstore.js file to guarantee that it is recreated when entering private browsing mode (session store)
  3. Enter private browsing mode
  4. Record the time stamp of the new sessionstore.js file – session store
  5. Add a new tab (b) and new tab (c)
  6. Close all three tabs (a, b, c)
  7. Record the time stamp of sesionstore.js – session store
  8. Exit private browsing mode
  9. Compare session store timestamps or pre and post browsing mode

Essentially,

  • On entry:
    • Save session, close all tabs, open a blank tab.
  • During:
    • Do not save any session data to disk, keep undo close tab data in memory.
  • On exit:
    • Clear all session data in memory, load saved session from disk.

The following plan, follows the second test I wrote for session store, it is as follows (following the landed unit test: browser_248970_b.js )

The plan makes sure that the session store remains functional during the private browsing mode. The “Browser Tests” part in the test plan is about ensuring this. I tested to ensure that that the private mode does not break functionality of the session store API. which is used elsewhere in the code (for example, that of duplicateTab method).

  1. Get the closed tab count of the current browser session
  2. Set up a state for Tab (A) and open new tab (A)
  3. Populate Tab (A) with form data
  4. Close Tab (A)
  5. Verify that the closed tab count has increased
  6. Verify that tab is in the undo list
  7. Enter private browsing mode
  8. Setup a state for Tab (B) and open new tab (B)
  9. Duplicate tab (B) to new Tab (C)
  10. Verify that it was duplicated properly
  11. Close tab (C) and (B)
Private Browsing Testing Area Private Browsing Unit Test (My Work)
Session Store Unit Test browser_248970_a.js & browser_248970_b.js & browser_248970_b_sample.html

Visual Representation of Session store testing area -> My Blog – Click Here

My tests have landed into the mozilla cross reference and are included in the trunk ready for Firefox 3.1! Ss_landing.jpg

What I learned?

  • October / November
    • More on Private Browsing – Functionality, features and usage, specifically session store, downloader manager, memory hashtables
    • Chrome Browser Tests – Similarities and differences between these forms of tests and XPCSHell unit tests
    • Writing Browser Tests using sample HTML files, manipulating session store data across entry and exit of private browsing mode
    • Other, multitude of other associated bugs related to #248970

With the completion of milestone 0.2, the deadline for Private Browsing testing has expired! Private Browsing has landed into Firefox 3.1!

Next milestone release will shift focus into testing audio and video tags in Firefox 3.1  – the newly supported HTML5 feature!

Community Interaction

Unlike in Milestone 0.1, this time around I primarily interacted through #developers and through conversation in email.

Stay tuned for more!

Cheers,

Aaron

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: