Moved constants from base.js to new file constants.js, eliminating magic...

... numbers in tests.
Great tip!


On Fri, Jul 11, 2014 at 8:18 AM, Bjvanminnen <notifications@github.com>
wrote:

> In test/solutions/maze/2_1.js:
>
> > @@ -12,7 +14,7 @@ module.exports = {
> >        description: "Verify solution",
> >        expected: {
> >          result: true,
> > -        testResult: 100
> > +        testResult: constants.TestResults.ALL_PASS
>
> One thing you could do that might be a little cleaner is to do
> var TestResults = require('../../../src/constants.js).TestResults;
> then elsewhere you can just do TestResults.ALL_PASS.
>
> Up to you as to whether you change this or not, as you have it is also
> fine.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/code-dot-org/blockly/pull/737/files#r14826114>.
>