Difference between revisions of "UrlMagic"

(Steps to get to DoneDone)
(Steps to get to DoneDone: Shouldnt have had the need to do it had edit_page been reliable)
Line 21: Line 21:
 
* <s>Write a test case for testing a portal page is redirected to it's domain.</s>
 
* <s>Write a test case for testing a portal page is redirected to it's domain.</s>
 
* <s>Write a test case for testing a non portal page is not redirected</s>
 
* <s>Write a test case for testing a non portal page is not redirected</s>
* Modifying test case to use fixtures instead of edit_page method that sometimes causes timeouts during rake test.  
+
* <s>Modifying test case to use fixtures instead of edit_page method that sometimes causes timeouts during rake test.</s>
 
* Write a test cases for testing the redirect.
 
* Write a test cases for testing the redirect.
 
* Write code in mediawiki that would redirect in case it finds the tag in the article.
 
* Write code in mediawiki that would redirect in case it finds the tag in the article.

Revision as of 10:20, 30 January 2008

OurWork Edit-chalk-10bo12.png

What (summary)

Pages in some portals should be accessible if and only if the site is being viewed from a specified domain. If a page is viewed in the wrong domain, the user is redirected to the right domain.

Why this is important

Lets us continue our portal branding in a way that gives sponsors a greater sense of ownership.

DoneDone

  • If a page is skinned via the <setSkin> tag, all attempted page views for that page are redirected to the proper domain. For example, if a page is called PortlandTechCompany, and is skinned PortlandTech, any attempts to reach www.aboutus.org/PortlandTechCompany are redirected (301 permanent) to www.portlandtech.net/PortlandTechCompany. Likewise, visiting www.portlandtech.net/NotInPortlandTech should redirect to www.aboutus.org/NotInPortlandTech
  • The detection of a particular portal is done using the skin-detection logic from CustomSkinForPortals. If this capability is insufficient, make sure that developers working on both projects address it together instead of creating our own solutions.
    • We may want to factor out the function get_portal_skin from design.php. The basic approach should stay the same.
    • Create a mapping between skin names and portal URLs
  • Develop this extension using an integration test written in Ruby using Net::Mechanize. See compost/test/integration/build_domain_test.rb for an example. We want to do this so that if we modify our platform in the future we have regression tests to know this capability still works.

Steps to get to DoneDone

  • Create a new branch named urlmagic for this task.
  • Bug in stage_branch script. SSL certificate not stored. Fix this.
  • Stage the urlmagic branch locally.
  • Understand domain page integration test class.
  • Write a test case for testing a portal page is redirected to it's domain.
  • Write a test case for testing a non portal page is not redirected
  • Modifying test case to use fixtures instead of edit_page method that sometimes causes timeouts during rake test.
  • Write a test cases for testing the redirect.
  • Write code in mediawiki that would redirect in case it finds the tag in the article.


Retrieved from "http://aboutus.com/index.php?title=UrlMagic&oldid=14650275"