1
0
Fork 0
Commit Graph

56 Commits (075e73e4d1f8f7e0919e65616cc32faac0191e01)

Author SHA1 Message Date
Mike Gerwitz 2c5bc6b63c uglify's mangle currently causing problems in IE8; removing until it can be further researched 2011-11-29 15:06:34 -05:00
Mike Gerwitz 0d0372cb87 [#25] Adding proper dirname to combined tests 2011-10-23 00:22:43 -04:00
Mike Gerwitz c1207eb3d5 Moved MemberBuilder-MethodTest into MemberBuilder subdir
- Altered combine script to support subdirs (note that the dir names aren't included in the combined file)
2011-10-20 23:40:30 -04:00
Mike Gerwitz c9b5fb32d0 Merge branch 'master' into virtual/refactor/master 2011-10-14 22:08:08 -04:00
Mike Gerwitz 4403bc4639 Updated URL in combined license 2011-10-14 22:07:45 -04:00
Mike Gerwitz c10fc5818a Added very basic formatted output and failure tolerance for test case
The one year anniversary of the beginning of the ease.js project is quickly
approaching. I find myself to be not quite where I had expected many months ago,
but find that the project has evolved so much further than I had event
originally anticipated. My main motivation behind the project continues to be
making my life at work easier, while providing an excellent library that others
can hopefully benefit from. If anything, it's a fascinating experiment and
clever hack around JavaScript.

Now I find myself with a newborn child (nearly four weeks old), who demands my
constant attention (and indeed, it is difficult to find the desire to put my
attention elsewhere). Still - I am a hacker. Software is my passion. So the
project must move forward.

I also find myself unwilling to create a blog for ease.js. I feel it's
inappropriate for a project that's in its (relative) infancy and does not have
much popularity (it has never been announced to anyone). As such, I feel that
commit messages will serve my purpose as useful journal entries regarding the
status of the project. They will also be interesting easter eggs for those who
would wish to seek them out for additional perspective on the project. (Granted,
one could easy script the discovery of such entries by examining the absurd
length of the commit message...perhaps the git log manpages would be useful).

So. Let's get back to the project.

ease.js is currently going through a strong refactoring in order to address
design issues that have begun to creep up as the project grew. The initial
design was a very simple one - a "series of modules", as it was originally
described in a CommonJS sense, that would provide features of a classical
Object-Oriented system. It would seem ironic that, having a focus on
classical Object-Oriented development, one would avoid developing the project in
such a paradigm. Instead, I wished to keep the design simple (because the
project seemed simple), more natural to JS developers (prototypal) and
performant (object literals do not have the overhead of instantiation). Well,
unfortunately, the project scope has increased drastically due to the success of
the implementation (and my playfulness), the chosen paradigm has become awkward
in itself and the performance benefit is indeed a micro-optimization when
compared with the performance of both the rest of the system and the system that
will implement ease.js as a framework.

You can only put off refactoring for so long before the system begins to trip
over itself and stop being a pleasure to work with. In fact, it's a slap in the
face. You develop this intricate and beautiful system (speaking collectively and
generally, of course) and it begins to feel tainted. In order to prevent it from
developing into a ball of mud - a truly unmaintainable mess - the act of
refactoring is inevitable, especially if we want to ensure that the project
survives and is actively developed for any length of time.

In this case, the glaring problem is that each of the modules are terribly,
tightly coupled. This reduces the flexibility of the system and forces us to
resort to a system riddled with conditionals. This becomes increasingly apparent
when we need to provide slightly different implementations between environments
(e.g. ES5/pre-ES5, production/development, etc and every combination).
Therefore, we need to decouple the modules in order to take advantage of
composition in order to provide more flexible feature sets depending on
environment.

What does this mean?

We need to move from object literals for the modules to prototypes (class-like,
but remember that ease.js exists because JS does not have "classes"). A number
of other prototypes can be extracted from the existing modules and abstracted to
the point where they can be appropriately injected where necessary. Rather than
using conditions for features such as fallbacks, we can encapsulate the entire
system in a facade that contains the features relevant to that particular
environment. This will also have the consequence that we can once again test
individual units rather than systems.

At the point of this commit (this entry was written before any work was done),
the major hurdle is refactoring the test cases so that they do not depend on
fallback logic and instead simply test specific units and skip the test if the
unit (the prototype) is not supported by the environment (e.g. proxies in a
pre-ES5 environment). This will allow us to finish refactoring the fallback and
environment-specific logic. It will also allow us to cleanly specify a fallback
implementation (through composition) in an ES5 environment while keeping ES5
detection mechanisms separate.

The remaining refactorings will likely be progressive. This all stemmed out of
the desire to add the method hiding feature, whose implementation varies
depending on environment. I want to get back to developing that feature so I can
get the first release (v0.1.0) out. Refactoring can continue after that point.
This project needs a version number so it can be used reliably.
2011-10-12 18:53:52 -04:00
Mike Gerwitz af653aaff7 Adjusted client-side module cleaning regex in combine.tpl 2011-08-31 00:23:23 -04:00
Mike Gerwitz 70142f5059 combine script will now include modules that are not require()'d by any other module 2011-08-28 17:33:44 -04:00
Mike Gerwitz 2d8e6d70a4 Replaced hard-coded, manually ordered module list with script (#25) 2011-08-14 18:45:16 -04:00
Mike Gerwitz fd95f38c87 Integrated VisibilityObjectFactory and removed old propobj (#25)
- Note that the excessive gluing is temporary
2011-08-13 23:58:08 -04:00
Mike Gerwitz c3a09c3613 Now incluiding *Test*.js files in full combined file (#25) 2011-08-13 23:14:22 -04:00
Mike Gerwitz 04318cc73d Errors during combine process now output to stderr 2011-08-13 23:12:15 -04:00
Mike Gerwitz 3530ec839c Added new prototypes to combined file (#25) 2011-08-13 23:11:59 -04:00
Mike Gerwitz 79652a1120 Moved non-fallback visibility object into VisibilityObjectFactory (system does not yet use it) (#25) 2011-08-11 23:11:37 -04:00
Mike Gerwitz 91a6fb51e9 Added assert.notStrictEqual to client-side assertions 2011-08-11 21:05:42 -04:00
Mike Gerwitz 7a579ab2aa Initial refactoring of class_builder module into ClassBuilder ctor (#25) 2011-08-09 17:27:26 -04:00
Mike Gerwitz 81fa2ae424 Merge branch 'master' into 'virtual/master'
- Resolved conflicts
2011-06-30 23:00:13 -04:00
Mike Gerwitz e2581deb90 Added Warning 2011-06-29 20:58:38 -04:00
Mike Gerwitz d6873d1cc9 Corrected client-side assert.deepEqual() to only perform object/array operations if both provided values are objects/arrays respectively 2011-06-11 21:32:11 -04:00
Mike Gerwitz d1044383d5 Fixed abstract/final class export in combined file
- I somehow had them swapped
2011-06-02 09:07:48 -04:00
Mike Gerwitz 99d0f34940 Added license to minified files 2011-05-23 18:59:50 -04:00
Mike Gerwitz b3455abcb9 Added notice in the event that UglifyJS is unavailable 2011-05-23 18:32:07 -04:00
Mike Gerwitz eed9465885 Added minification script 2011-05-23 18:27:42 -04:00
Mike Gerwitz fdee02adc9 Combined file now exports {Final,Abstract}Class 2011-05-23 07:12:46 -04:00
Mike Gerwitz af411edf43 Implemented GH#7 - Implement assert.deepEqual() client-side 2011-05-22 22:48:46 -04:00
Mike Gerwitz e0de030cee Implemented AbstractClass
- Some of this functionality requires further refactoring
2011-05-22 16:08:48 -04:00
Mike Gerwitz 9690663d1c Added support for final classes
- This commit was originally many. Unfortunately, certain Git objects became
  corrupt shortly after my 500th commit due to HDD issues. Due to the scope, I
  was unable to recover the set of commits I needed (after an hour of trying
  every method).
  - Fortunately, vim's swap files came to the rescue. Had I been able to
    properly shut down my PC, I would have been rather frustrated.
2011-05-22 11:19:51 -04:00
Mike Gerwitz 969687e770 Added strictEqual to client-side assertions 2011-04-13 23:48:15 -04:00
Mike Gerwitz adfc607c8b Continued moving class creation logic into class_builder module
- Again, very messy. Not yet complete.
2011-03-27 23:04:40 -04:00
Mike Gerwitz 87e7872f61 Using __dirname for modules rather than relative path 2011-03-27 02:02:04 -04:00
Mike Gerwitz af8f0b1566 Began refactoring into class_builder module
- Sloppy thusfar. Baby steps.
2011-03-27 01:57:17 -04:00
Mike Gerwitz 9a135a064c Added pre-ES5 test to ensure we can catch fallback bugs quickly between browser tests (preferably, before even committing) 2011-03-13 22:08:08 -04:00
Mike Gerwitz 960be880ab Merge branch 'master' into visibility/master 2011-03-07 23:09:02 -05:00
Mike Gerwitz ab8faad53f /bin/{bash => sh} to support system with only sh installed
- e.g. FreeBSD
- Nothing in the scripts actually needs BASH anyway
2011-03-07 22:54:59 -05:00
Mike Gerwitz 00378da630 Merge branch 'master' into visibility/master 2011-03-07 09:03:34 -05:00
Mike Gerwitz 522165fb6a No longer clearing test name output on successful browser test 2011-03-07 08:29:18 -05:00
Mike Gerwitz e463d2c411 Began factoring property instance object out of class module 2011-03-06 18:19:19 -05:00
Mike Gerwitz 4eda438f14 Outputting current test for browser
- Output is hidden on success, but useful on failure
2011-03-06 10:55:13 -05:00
Mike Gerwitz 6a3789a730 Test failure message will now show up in browsers like IE6 2011-03-06 10:20:38 -05:00
Mike Gerwitz 0ccab4f8d9 Corrected test combine process; was not including tests in ease-full.js 2011-03-06 10:15:32 -05:00
Mike Gerwitz 4987856a46 Combine process now wraps using module rather than only exports
- This will allow us to overwrite the 'exports' object
2011-03-03 14:14:10 -05:00
Mike Gerwitz 906e468cdf Refactored test logic that will be shared between multiple members into inc-member_builder-common.js to reduce code duplication 2011-01-21 20:46:24 -05:00
Mike Gerwitz 23a7d9d540 Began adding member_builder 2011-01-18 23:47:58 -05:00
Mike Gerwitz 5b3ecf853b Exposed Interface 2010-12-30 09:24:52 -05:00
Mike Gerwitz 7b69a09a5a Altered browser-test.html failure message 2010-12-28 13:37:53 -05:00
Mike Gerwitz 729d7083da Added function to prefix failed client-side assertions with 'Assertion failed: ' 2010-12-28 13:26:04 -05:00
Mike Gerwitz 0ea6df4c9e Added browser-test.html 2010-12-28 13:21:41 -05:00
Mike Gerwitz 34af8eec95 Moved @license (and changed to @preserved) so Closure Compiler would properly retain the block 2010-12-28 10:36:39 -05:00
Mike Gerwitz 5dcc4452be Removing trailing commas from combine-test.tpl 2010-12-28 08:37:23 -05:00
Mike Gerwitz 3347b8f6d5 Added ease-full.js, which includes tests to be run client-side (initial implementation; may be buggy) 2010-12-28 00:23:13 -05:00