Closed
Bug 497362
Opened 17 years ago
Closed 17 years ago
Test cases for htaccess rules
Categories
(support.mozilla.org :: General, defect)
Tracking
(Not tracked)
VERIFIED
FIXED
1.3
People
(Reporter: laura, Assigned: vish_moz)
References
()
Details
(Whiteboard: sumo_only)
As discussed we need to come up with a set of htaccess tests. I'll help you out with this.
Updated•17 years ago
|
OS: Mac OS X → All
Comment 1•17 years ago
|
||
The SUMO file in question is viewable at http://viewvc.svn.mozilla.org/vc/projects/sumo/trunk/webroot/htaccess.dist?view=log.
I've started a (very limited) _manual_ Litmus test over at https://litmus.mozilla.org/show_test.cgi?id=7874.
I think I'm going to automate it in Selenium, though; seems the quickest and even easiest way to test this; Vishal, others: thoughts?
Comment 2•17 years ago
|
||
Selenium should work well.
For what it's worth, from what I've seen of the .htaccess file, there are two parts to test:
1. The FileMatch, which we test for security issues
2. The Rewrites, which we test for functionality
On the first, ensure that the pages returns "403 Access Forbidden", and on the second set make sure that rewrite requests behave as intended.
Comment 3•17 years ago
|
||
Proof of concept up at http://viewvc.svn.mozilla.org/vc/projects/sumo/trunk/tests/frontend/htaccess.dist%20Selenium%20tests.html?view=log.
Probably could be written a _lot_ cleaner; I don't yet have the Selenium chops to do variable substitution/while() loops. Additionally, could use:
1. Filling out (and commenting where missing sections belong)
2. Better commenting
We really need the variable substitution/while() loops to iterate through an array of languages/locales and more fully test all the combinations (would be hard to edit this testcase by hand).
Updated•17 years ago
|
Assignee: stephen.donner → mozwebqa
Comment 4•17 years ago
|
||
Assigning to Vishal, as he's pretty much knocked this one out of the park; thanks, Vishal!
Assignee: mozwebqa → vish.mozilla
Updated•17 years ago
|
Status: NEW → ASSIGNED
| Reporter | ||
Comment 5•17 years ago
|
||
Stephen checked this in, and Vishal documented it. Please add the location of docs.
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
| Assignee | ||
Comment 6•17 years ago
|
||
Here's the automation script that runs on Selenium Remote Control & PHP to test the htaccess rewrites:
https://wiki.mozilla.org/QA/Execution/Web_Testing/SUMO/Selenium/htaccess
The following links redirect back to en-US:
af
be
bg
en-GB
ka
ku
ml
es-MX
Comment 7•17 years ago
|
||
Thx, Vishal; verified fixed (I've seen the script run, and fail for those locales mentioned above, so it's doing its job).
Status: RESOLVED → VERIFIED
Updated•16 years ago
|
Whiteboard: sumo_only
You need to log in
before you can comment on or make changes to this bug.
Description
•