Skip to content

Commit 9a57c42

Browse files
committed
Updated README and added Jasmine as a dev dependency for Google Maps API testing; moved specs to combined tests/ folder and added Travis CI support for Node testing
1 parent 31aecb8 commit 9a57c42

8 files changed

Lines changed: 1263 additions & 2649 deletions

File tree

‎README.md‎

Lines changed: 17 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ Wicket is a lightweight library for translating between [Well-Known Text (WKT)](
66
* ESRI ArcGIS JavaScript API [(demo)](http://arthur-e.github.com/Wicket/sandbox-arcgis.html)
77
* Potentially any other web mapping framework through serialization and de-serialization of GeoJSON (with `JSON.parse`)
88

9+
The core Wicket library and the Leaflet extension are both compatible with Node.js; the Google Maps and ArcGIS API extensions will not work in Node.js because they require a browser.
10+
911
If you are looking for [Apache Wicket](http://wicket.apache.org/), the web-app development framework for Java, [you'll find it here](http://wicket.apache.org/).
1012

1113
## License ##
@@ -64,6 +66,21 @@ Use `fromObject()` instead, as in the following example.
6466
* [wellknown](https://github.com/mapbox/wellknown)
6567
* [OpenLayers WKT](https://github.com/openlayers/openlayers/blob/master/lib/OpenLayers/Format/WKT.js)
6668

69+
## Dependencies and Build Information ##
70+
71+
**Wicket has zero dependencies**, however, JSON parsing (from strings) is not provided.
72+
Wicket looks for the function `JSON.parse`, which is provided in most modern browsers (get it with [this library](https://github.com/douglascrockford/JSON-js/blob/master/json2.js), if you need to support older browsers).
73+
74+
Minified versions can be generated via:
75+
76+
npm run build
77+
78+
### Testing ###
79+
80+
npm test
81+
82+
The Google Maps API extension cannot be tested by Node.js at the command line; it requires a browser. The Google Maps API tests are run by Jasmine; navigate to the file `tests/wicket-gmap3.html` in a web browser.
83+
6784
## Documentation ##
6885

6986
Read the documentation [here](http://arthur-e.github.io/Wicket/doc/out/). Documentation can be generated with [JSDoc 3](https://github.com/jsdoc3/jsdoc).
@@ -78,33 +95,6 @@ Or, with Node installed:
7895

7996
Either way, make sure you invoke `jsdoc` from a directory in which you have write access; it will output documentation to your current working directory.
8097

81-
## Dependencies and Build Information ##
82-
83-
**Wicket has zero dependencies**, however, JSON parsing (from strings) is not provided.
84-
Wicket looks for the function `JSON.parse`, which is provided in most modern browsers (get it with [this library](https://github.com/douglascrockford/JSON-js/blob/master/json2.js), if you need to support older browsers).
85-
86-
**Minified versions** can be generated with `uglify-js` (`sudo npm install uglify-js -g`):
87-
88-
./node_modules/uglify-js/bin/uglifyjs wicket.js -o wicket.min.js
89-
90-
There is now a script included that will do this automatically for all of Wicket's source code:
91-
92-
. refactor.sh
93-
94-
### Testing ###
95-
96-
Testing Wicket is easy with [Jasmine](https://github.com/pivotal/jasmine). Here's a quick script to (describe how to) install it if you don't:
97-
98-
sudo mkdir -p /var/www/static/
99-
cd /var/www/static/
100-
sudo git clone git://github.com/pivotal/jasmine.git
101-
cd jasmine/dist
102-
sudo unzip ./*.zip
103-
# If using a distribution other than 2.0.0...
104-
ln -s jasmine-X.X.X jasmine-2.0.0
105-
106-
Once you have Jasmine installed and the paths match those expected in `tests/SpecRunner.html` (or you changed them to match your Jasmine installation) then just point your browser to `localhost/static/wicket/tests/SpecRunner.html`.
107-
10898
## Colophon ##
10999

110100
### Motivation ###

0 commit comments

Comments
 (0)