Skip to content

Commit

Permalink
Added ApiUtil - a place for adding utility methods for work with API
Browse files Browse the repository at this point in the history
  • Loading branch information
Hovhannes Babayan committed Dec 24, 2014
1 parent 20cc2de commit 3353e39
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
4 changes: 3 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
var ApiFactory = require('./src/ApiFactory');
var Api = require('./src/Api');
var ApiUtil = require('./src/ApiUtil');

module.exports = {
Api: Api,
ApiFactory: ApiFactory
ApiFactory: ApiFactory,
ApiUtil: ApiUtil
};
5 changes: 5 additions & 0 deletions src/ApiUtil.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
var ApiUtil = {

};

module.exports = ApiUtil;
4 changes: 2 additions & 2 deletions test/ApiFactorySpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ var ApiFactory = require('./../src/ApiFactory');
var Api = require('./../src/Api');


describe('Api.getInstance() when called for the frist time', function() {
describe('ApiFactory.getInstance() when called for the frist time', function() {
it('should throw when called for the first time without config', function(){
expect(function() {
ApiFactory.getInstance()
Expand All @@ -13,7 +13,7 @@ describe('Api.getInstance() when called for the frist time', function() {
});


describe('Api.getInstance() when called multiple times', function() {
describe('ApiFactory.getInstance() when called multiple times', function() {
var firstInstance;

beforeEach(function() {
Expand Down
8 changes: 8 additions & 0 deletions test/ApiUtilSpec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
var expect = require('chai').expect;

var ApiUtil = require('./../src/ApiUtil');


describe('ApiUtil', function() {

});

0 comments on commit 3353e39

Please sign in to comment.