update tests
This commit is contained in:
parent
d2be8aefc0
commit
bbe87e41fa
2 changed files with 11 additions and 1 deletions
|
|
@ -86,7 +86,7 @@ exports.moduleUrl = function(name, component) {
|
|||
base = base.replace(re, "");
|
||||
}
|
||||
|
||||
if (!base && parts.length > 1)
|
||||
if ((!base || base == component) && parts.length > 1)
|
||||
base = parts[parts.length - 2];
|
||||
var path = options[component + "Path"];
|
||||
if (path == null) {
|
||||
|
|
|
|||
|
|
@ -60,6 +60,16 @@ module.exports = {
|
|||
url = config.moduleUrl("foo/1", "theme");
|
||||
assert.equal(url, "a/b1.js");
|
||||
|
||||
url = config.moduleUrl("snippets/js");
|
||||
assert.equal(url, "a/b/snippets/js.js");
|
||||
|
||||
config.setModuleUrl("snippets/js", "_.js");
|
||||
url = config.moduleUrl("snippets/js");
|
||||
assert.equal(url, "_.js");
|
||||
|
||||
url = config.moduleUrl("ace/ext/textarea");
|
||||
assert.equal(url, "a/b/ext-textarea.js");
|
||||
|
||||
assert.equal();
|
||||
},
|
||||
"test: define options" : function() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue