Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #69 from Postmedia/dependencies

updated depenedencies for core required librairies, updated node version...
  • Loading branch information...
commit 00dd8a3048e7d935d2f7546d8b19e020f96b44a4 2 parents 584fc14 + 00eb2f2
Edward de Groot authored
View
2  .travis.yml
@@ -1,6 +1,6 @@
language: node_js
node_js:
- - 0.8.x
+ - 0.8
notifications:
email:
recipients:
View
16 History.md
@@ -1,3 +1,19 @@
+0.7.2 / 2014-05-12
+==================
+ * Dependency update to allow pantry v0.7.x
+ * Dependency update to allow request v2.36.x
+ * Dependency update to allow express v3.10.x
+ * Dependency update to allow hjs v0.0.6
+ * Dependency update to allow hogan.js v3.0.x
+ * Dependency update to allow run v1.2.x
+ * Dependency update to allow mocha v1.20.x
+ * Dependency update to allow should v4.0.x
+ * Examples - added parameter and example help for dutchie timbit
+ * Added dependency for should-http v0.0.2 augments should v4.x
+ * Updated node engine support from 0.8.x to up to 0.10.x
+ * Updated npm to 1.x
+ * Changed test to require '-c' or '--coffee' to use coffee-script
+
0.7.1 / 2013-07-16
==================
* Dependency update to allow pantry v0.5.x
View
3  bin/template/test/timbits-test.coffee
@@ -7,6 +7,9 @@ timbits = require 'timbits'
should = require 'timbits/node_modules/should'
request = require 'timbits/node_modules/request'
+# should http extensions
+require 'timbits/node_modules/should-http'
+
port = 8785
alltests = process.env.TIMBITS_TEST_WHICH is 'all'
View
3  bin/template/test/timbits-test.js
@@ -8,6 +8,9 @@ var timbits = require('../lib/timbits')
, path = require('path')
, request = require('request')
+// load hhtp extensions for should
+require('should-http');
+
// set testing environment
var port = 8785
, alltests = process.env.TIMBITS_TEST_WHICH === 'all';
View
5 bin/timbits
@@ -302,7 +302,7 @@ switch (argv._[0]) {
case 't':
case 'test':
- options = ['--compilers', 'coffee:coffee-script', '--growl', '--colors'];
+ options = ['--growl', '--colors'];
for (key in argv) {
switch(key){
case 'reporter':
@@ -317,6 +317,9 @@ switch (argv._[0]) {
case 'bail':
options.push('--' + key)
break;
+ case 'coffee':
+ options.push( '--compilers', 'coffee:coffee-script' );
+ break;
}
}
runTests(argv.a, options);
View
2  examples/timbits/chocolate.js
@@ -28,7 +28,7 @@ timbit.params = {
description: 'The Wordpress site to query',
required: true,
strict: false,
- values: ['sports.nationalpost.com', 'blog.windsorstar.com']
+ values: ['sports.nationalpost.com', 'o.canada.com']
},
tag: {
description: 'Tag to filter by',
View
39 examples/timbits/dutchie.js
@@ -6,6 +6,45 @@ var timbits = require('../../lib/timbits');
// create and export the timbit
var timbit = module.exports = new timbits.Timbit();
+// additional timbit implementation code follows...
+timbit.about = '\
+ Example of a timbit which re-uses another timbits views\
+ This timbit will query Wordpress API and display the results\
+ This timbit re-uses the views from the chocolate timbit\
+ ';
+
+timbit.examples = [
+ {
+ href: '/dutchie/?site=news.nationalpost.com',
+ caption: 'Latest news from The National Post'
+ }, {
+ href: '/dutchie/alternate-view?site=news.nationalpost.com&tag=Apple&number=5',
+ caption: 'Latest five news posts on Apple from The National Post'
+ }
+];
+
+timbit.params = {
+ site: {
+ description: 'The Wordpress site to query',
+ required: true,
+ strict: false,
+ values: ['news.nationalpost.com', 'o.canada.com']
+ },
+ tag: {
+ description: 'Tag to filter by',
+ required: false,
+ strict: false,
+ values: ['Apple', 'Canada']
+ },
+ "number": {
+ description: 'The number of posts to display',
+ alias: 'rpp',
+ "default": 10,
+ strict: false,
+ values: [3, 5, 10]
+ }
+};
+
// let's just re-use the chocolate timbit views and use additional cache time
timbit.viewBase = 'chocolate';
timbit.maxAge = 300;
View
23 package.json
@@ -1,7 +1,7 @@
{
"name": "timbits",
"description": "Widget framework based on Express",
- "version": "0.7.1",
+ "version": "0.7.2",
"homepage": "https://github.com/Postmedia/timbits",
"author": "Edward de Groot <edegroot@postmedia.com> (http://mred9.com)",
"contributors": [
@@ -12,16 +12,17 @@
],
"dependencies": {
"winston": "~0.7.1",
- "express": "~3.2.6",
- "hjs": "~0.0.4",
- "hogan.js": "~2.0.0",
- "pantry": "~0.5.0",
- "request": "~2.11",
+ "express": "~3.10.5",
+ "hjs": "~0.0.6",
+ "hogan.js": "~3.0.1",
+ "pantry": "~0.7.0",
+ "request": "~2.34",
"optimist": "~0.3.4",
- "run": "~1.0",
- "mocha": "~1.6",
- "should": "~1.2",
- "which": "~1.0.5"
+ "run": "~1.2",
+ "mocha": "~1.20.1",
+ "should": "~4.0.4",
+ "which": "~1.0.5",
+ "should-http": "~0.0.2"
},
"bugs": { "url": "https://github.com/Postmedia/timbits/issues"},
"licenses": [
@@ -36,6 +37,6 @@
"scripts": {
"test": "mocha"
},
- "engines": { "node": "0.8.x", "npm": "1.1.x" }
+ "engines": { "node": ">=0.8.0 <0.11", "npm": "1.x" }
}
View
5 test/timbits-test.js
@@ -7,7 +7,10 @@ var timbits = require('../lib/timbits')
, should = require('should')
, path = require('path')
, request = require('request')
-
+
+// load hhtp extensions for should
+require('should-http');
+
// set testing environment
var homeFolder = path.join(process.cwd(), "examples")
, port = 8785
Please sign in to comment.
Something went wrong with that request. Please try again.