Name | Date | Size | |
---|---|---|---|
.. | 2012-04-04 20:01:15 | 100 | |
build-base.properties | 2011-12-03 02:42:05 | 690 | |
build-base.xml | 2011-06-07 20:21:31 | 504 | |
build-loader.xml | 2011-06-08 17:11:32 | 624 | |
build-rollup.properties | 2011-06-10 20:34:13 | 682 | |
build-rollup.xml | 2011-06-07 20:21:31 | 506 | |
build-yui3.properties | 2011-06-10 20:34:13 | 678 | |
build-yui3.xml | 2011-06-07 20:21:31 | 504 | |
build.properties | 2010-03-10 09:27:13 | 233 | |
build.xml | 2011-06-08 17:11:32 | 632 | |
HISTORY.md | 2012-01-31 00:00:14 | 4.4 KiB | |
js | 2012-03-30 02:29:14 | 7 | |
loader-extras.xml | 2012-04-03 21:39:14 | 1 KiB | |
loader.meta.properties | 2012-04-04 20:01:15 | 71 | |
Makefile | 2011-11-07 20:19:52 | 294 | |
meta | 2011-12-03 02:42:05 | 3 | |
README.md | 2011-06-30 21:17:29 | 1.9 KiB | |
scripts | 2011-11-07 20:19:52 | 11 | |
template | 2011-07-25 18:52:46 | 4 | |
tests | 2012-03-26 20:52:19 | 11 |
README.md
YUI Loader
==========
Processes dependencies and dynamically loads script and css for YUI and external modules.
Development
-----------
The Loader build provides a Makefile for easy building. The Makefile contains the following targets:
* `all` - Runs `build` then `test` (the default)
* `build` - A passthrough to `ant all` (requires nodejs and python)
* `meta` - Runs the `scripts/meta_join.py` to build the meta data (requires python)
* `check` - Runs the `scripts/meta_check.js` to check meta-data for inconsistencies (requires nodejs)
* `test` - Runs a series of NodeJS based CLI tests (requires nodejs with yuitest installed)
* `gallery` - Fetches and updates the meta-data with the latest gallery build (requires nodejs)
Testing
-------
npm -g i yuitest
There is one set of automated CLI tests that can be run with `make test`. This will do a simple
`Loader` call for a module and then check the Loader's `sorted` array for that module. A very simple
smoke test to determine if Loader is functioning properly.
There is an advanced test under `tests/server`. This test will attempt to load every yui3 module
from one of these places:
* `STATIC` local static files
* `COMBO` local combo handler
* `LOADER` local combo handle after fetching loader
* `STAR` use star `YUI().use('*')` with a dynamic script generated on the server
* `RLS` A local RLS server (not supported until YLS is released)
To run these tests, `cd tests/server`
npm -g i yui3 express combohandler
export STAR=1; ./server.js
export LOCAL=1; export STAR=1; ./server.js
export LOCAL=1; export STAR=1; export COMBO=1; ./server.js
export LOCAL=1; export STAR=1; export COMBO=1; export LOADER=1; ./server.js #The normal test to run
export LOCAL=1; export STAR=1; export COMBO=1; export RLS=1; ./server.js
export LOCAL=1; export STAR=1; export COMBO=1; export LOADER=1; export RLS=1; ./server.js