Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(2481)

Issue 6856070: Remove "requires" from modules-debug.js

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 5 months ago by thiago
Modified:
11 years, 5 months ago
Reviewers:
mp+135198, matthew.scott, gary.poster
Visibility:
Public.

Description

Remove "requires" from modules-debug.js The minification process does not read the "requires" parameters defined in "modules-debug.js". This parameter should be defined in each custom yui object that uses some kind of internal or external requirement. The sole use of "all-app-debug.js" is to define the fullpath of the file that defines a given module. This patch removes all the existing "requires" properties from "modules-debug.js" and add then where they are needed. https://code.launchpad.net/~tveronezi/juju-gui/change-requires-param/+merge/135198 (do not edit description out of merge proposal)

Patch Set 1 #

Patch Set 2 : Remove "requires" from modules-debug.js #

Total comments: 14

Patch Set 3 : Remove "requires" from modules-debug.js #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+810 lines, -847 lines) Patch
A [revision details] View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M app/app.js View 1 chunk +1 line, -0 lines 0 comments Download
M app/models/charm.js View 1 chunk +2 lines, -1 line 0 comments Download
M app/models/models.js View 1 chunk +1 line, -0 lines 0 comments Download
M app/modules-debug.js View 1 2 4 chunks +8 lines, -12 lines 1 comment Download
M app/store/charm.js View 1 chunk +1 line, -0 lines 0 comments Download
M test/test_app.js View 1 2 1 chunk +176 lines, -191 lines 1 comment Download
M test/test_app_hotkeys.js View 1 2 2 chunks +52 lines, -52 lines 0 comments Download
M test/test_model.js View 1 2 4 chunks +18 lines, -25 lines 0 comments Download
M test/test_notifications.js View 1 2 1 chunk +454 lines, -469 lines 0 comments Download
M test/test_notifier_widget.js View 1 2 1 chunk +95 lines, -97 lines 0 comments Download

Messages

Total messages: 7
thiago
Please take a look.
11 years, 5 months ago (2012-11-20 17:00:35 UTC) #1
thiago
Please take a look.
11 years, 5 months ago (2012-11-20 19:03:30 UTC) #2
gary.poster
Hi Thiago. Thank you for the quick turnaround on this fix. I have only done ...
11 years, 5 months ago (2012-11-20 21:01:19 UTC) #3
matthew.scott
From IRC, this branch looks good functionally. +1 from me, so long as Gary's comments ...
11 years, 5 months ago (2012-11-20 21:26:04 UTC) #4
thiago
Thanks for your review, guys! https://codereview.appspot.com/6856070/diff/3001/app/modules-debug.js File app/modules-debug.js (left): https://codereview.appspot.com/6856070/diff/3001/app/modules-debug.js#oldcode96 app/modules-debug.js:96: requires: ['juju-charm-id'], On 2012/11/20 ...
11 years, 5 months ago (2012-11-20 23:05:24 UTC) #5
thiago
Please take a look.
11 years, 5 months ago (2012-11-20 23:09:47 UTC) #6
gary.poster
11 years, 5 months ago (2012-11-21 15:41:51 UTC) #7
Hi Thiago.  I like what you did with the tests, even though I wish it didn't
have to be part of this branch.  I'm OK with it landing though.

As I mentioned on IRC, I do see a test failure, but it seems shallow.  Please
fix that, and maybe the small comment change I suggest.

Thank you,

Gary

https://codereview.appspot.com/6856070/diff/9001/app/modules-debug.js
File app/modules-debug.js (right):

https://codereview.appspot.com/6856070/diff/9001/app/modules-debug.js#newcode10
app/modules-debug.js:10: // minimizer will not parse it.
Maybe add "Please put in in the module itself, instead."

https://codereview.appspot.com/6856070/diff/9001/test/test_app.js
File test/test_app.js (right):

https://codereview.appspot.com/6856070/diff/9001/test/test_app.js#newcode34
test/test_app.js:34: YUI(GlobalConfig).use(['juju-gui', 'juju-tests-utils'],
function(Y) {
This looks good to me.  However, it is a big change to how we write our tests,
and not consistently applied to our tests.  As I said on IRC, I think there is a
good argument to change our tests to be written this way, but I don't understand
why we need to change them here, in this branch.

In the interest of progress, I'm ok with landing this if you then make a
retrospective discussion card for us to collectively determine the way we want
to move forward.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b