mozilla/kuma — pull request #332 by darkwing (2012-07-03 00:04:10+00:00)
Title: fix bug 770338 - Preventing unnecessary redirect documents

Upon valid "new" and "translate" forms submissions, whereby a parent/child structure existed in the slug, an entry was created incorrectly for "/child" and then correctly for "parent/child". This prevents the "/child" redirect from being created.

Tests also added.

How to spot-check:

1. Create a parent document with slug "parentdoc"
2. Create a child document with slug "childdoc"
3. You should be at "en-US/docs/parentdoc/childdoc"
4. Try to hit "en-US/docs/childdoc" -- you should get a 404
5. Translate to new language; you should be at "es/docs/parentdoc/childdoc"
6. Try to hit "es/docs/childdoc" -- you should get a 404.