Skip to content

Commit 0968f33

Browse files
committed
fixed #6
superagent dependency set to 0.17.0
1 parent 60a7d86 commit 0968f33

File tree

4 files changed

+25
-27
lines changed

4 files changed

+25
-27
lines changed

README.md

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ A CMIS javascript library for node and browser
1515

1616
### browser
1717

18-
You can download minified version (with dependencies) from https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.1.min-all.js
18+
You can download minified version (with dependencies) from https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.6.min-all.js
1919

20-
<script type="text/javascript" src="cmis-0.1.1.min-all.js"></script>
20+
<script type="text/javascript" src="cmis-0.1.6.min-all.js"></script>
2121

2222
*Note:*
23-
You have to include [superagent](http://visionmedia.github.io/) if you want to use [cmis-0.1.1.js](https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.1.js) or [cmis-0.1.1.min.js](https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.1.min.js)
23+
You have to include [superagent](http://visionmedia.github.io/) if you want to use [cmis-0.1.6.js](https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.1.js) or [cmis-0.1.6.min.js](https://github.com/agea/CmisJS/releases/download/v0.1.1/cmis.0.1.6.min.js)
2424

2525
## Usage
2626

@@ -55,20 +55,20 @@ Install grunt:
5555
Clone the repo:
5656

5757
$ git clone https://github.com/agea/CmisJS/
58-
58+
5959
Install dependencies:
6060

6161
$ cd CmisJS
6262

6363
$ npm install
6464

6565
### Running tests on node
66-
66+
6767
(http://cmis.alfresco.com will be used as test repository)
6868

6969
$ grunt test
7070

71-
You can specify different url, username and password
71+
You can specify different url, username and password
7272

7373
$ grunt test --url http://localhost:8080/alfresco/cmisbrowser --user admin --password secret
7474

@@ -89,4 +89,3 @@ To change username and password you can specify them in the url
8989
##License
9090

9191
MIT license - [http://www.opensource.org/licenses/mit-license.php](http://www.opensource.org/licenses/mit-license.php)
92-

bower.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
{
22
"name": "cmis",
3-
"version": "0.1.5",
3+
"version": "0.1.6",
44
"dependencies": {
5-
"superagent":""
5+
"superagent":"~0.17.0"
66
},
77
"devDependencies": {
8-
8+
99
}
1010
}
11-

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"title": "CmisJS",
33
"name": "cmis",
4-
"version": "0.1.5",
4+
"version": "0.1.6",
55
"homepage": "http://github.com/agea/CmisJS",
66
"description": "a CMIS client library written in Javascript for node and the browser",
77
"author": {
@@ -14,7 +14,7 @@
1414
"url": "git://github.com/agea/cmisjs.git"
1515
},
1616
"dependencies": {
17-
"superagent": ""
17+
"superagent": "~0.17.0"
1818
},
1919
"devDependencies": {
2020
"grunt-cli": "",

test/spec.js

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ session.setGlobalHandlers(console.log, console.log);
4848
var rootId;
4949

5050
describe('CmisJS library test', function () {
51-
51+
5252
it('should connect to a repository', function (done) {
5353
session.setCredentials(username, password).loadRepositories()
5454
.ok(function (data) {
@@ -123,7 +123,7 @@ describe('CmisJS library test', function () {
123123
queryName:'test:testDoc',
124124
fileable:true,
125125
includedInSupertypeQuery:true,
126-
creatable:true,
126+
creatable:true,
127127
fulltextIndexed:false,
128128
queryable:false,
129129
controllableACL:true,
@@ -144,7 +144,7 @@ describe('CmisJS library test', function () {
144144
cardinality:'single',
145145
queryable:true,
146146
orderable:true,
147-
}
147+
}
148148
}
149149
}
150150

@@ -267,7 +267,7 @@ describe('CmisJS library test', function () {
267267
it('should return folder parent', function (done) {
268268
session.getFolderParent(randomFolderId).ok(function (data) {
269269
assert(
270-
data.succinctProperties['cmis:objectId']==rootId,
270+
data.succinctProperties['cmis:objectId']==rootId,
271271
"should return root folder");
272272
done();
273273
});
@@ -276,7 +276,7 @@ describe('CmisJS library test', function () {
276276
it('should return object parents', function (done) {
277277
session.getParents(randomFolderId).ok(function (data) {
278278
assert(
279-
data[0].object.succinctProperties['cmis:objectId']==rootId,
279+
data[0].object.succinctProperties['cmis:objectId']==rootId,
280280
"should return root folder");
281281
done();
282282
});
@@ -285,7 +285,7 @@ describe('CmisJS library test', function () {
285285
it('should return allowable actions', function (done) {
286286
session.getAllowableActions(randomFolderId).ok(function (data) {
287287
assert(
288-
data.canCreateDocument!==undefined,
288+
data.canCreateDocument!==undefined,
289289
"create document action should be defined");
290290
done();
291291
});
@@ -294,7 +294,7 @@ describe('CmisJS library test', function () {
294294
it('should return object properties', function (done) {
295295
session.getProperties(randomFolderId).ok(function (data) {
296296
assert(
297-
data['cmis:name']==randomFolder,
297+
data['cmis:name']==randomFolder,
298298
"folder name should be " + randomFolder);
299299
done();
300300
});
@@ -304,34 +304,34 @@ describe('CmisJS library test', function () {
304304
session.updateProperties(firstChildId,
305305
{'cmis:name':'First Level Renamed'}).ok(function (data) {
306306
assert(
307-
data.succinctProperties['cmis:name']=='First Level Renamed',
307+
data.succinctProperties['cmis:name']=='First Level Renamed',
308308
"folder name should be 'First Level Renamed'");
309309
done();
310310
});
311-
});
311+
});
312312

313313
it('should move specified object', function (done) {
314314
session.moveObject(secondChildId, firstChildId, randomFolderId).ok(function (data) {
315315
assert(data.succinctProperties['cmis:parentId']==randomFolderId,
316316
"Parent folder id should be " + randomFolderId);
317317
done();
318318
});
319-
});
319+
});
320320

321321
var docId
322322
var txt = 'this is the document content';
323323
it('should create a document', function (done) {
324324
var aces = {}
325325
aces[username] = ['cmis:read'];
326-
session.createDocument(randomFolderId, txt, 'test.txt',
326+
session.createDocument(randomFolderId, txt, 'test.txt',
327327
'text/plain', undefined, undefined, aces).ok(function (data) {
328328
docId = data.succinctProperties['cmis:objectId'];
329329
done();
330330
});
331331
});
332332

333333
it('should update properties of documents', function (done) {
334-
session.bulkUpdateProperties([docId],
334+
session.bulkUpdateProperties([docId],
335335
{'cmis:name':'mod-test.txt'}).ok(function (data) {
336336
assert(data,'OK');
337337
done();
@@ -404,7 +404,7 @@ describe('CmisJS library test', function () {
404404
done();
405405
return;
406406
}
407-
session.checkIn(checkOutId, true, 'test-checkedin.txt',
407+
session.checkIn(checkOutId, true, 'test-checkedin.txt',
408408
txt, 'the comment!').ok(function (data) {
409409
docId = data.succinctProperties['cmis:objectId'].split(";")[0];
410410
done();
@@ -439,7 +439,7 @@ describe('CmisJS library test', function () {
439439
if (!appended){
440440
console.log("skipping")
441441
done();
442-
return;
442+
return;
443443
}
444444
session.getContentStream(docId).ok(function (data) {
445445
assert(data == txt+appended,'document content should be "' + txt + appended + '"');

0 commit comments

Comments
 (0)