unit test url building and move more into requirejs config