Skip to content

Commit

Permalink
Merge pull request #3884 from Automattic/update/purchases-single-test…
Browse files Browse the repository at this point in the history
…-runner

Purchases: Add unit tests to single test runner
  • Loading branch information
gziolo committed Mar 9, 2016
2 parents d3fa383 + 7a14fbd commit f2479aa
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 31 deletions.
12 changes: 0 additions & 12 deletions client/lib/purchases/Makefile

This file was deleted.

12 changes: 0 additions & 12 deletions client/lib/purchases/stored-cards/Makefile

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { expect } from 'chai';
import { createStoredCardsArray } from '../assembler.js';
import { STORED_CARDS_FROM_API, STORED_CARDS } from './data';

describe( 'Stored Cards assembler', () => {
describe( 'assembler', () => {
it( 'should be a function', () => {
expect( createStoredCardsArray ).to.be.an( 'function' );
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import Dispatcher from 'dispatcher';
import { STORED_CARDS_FROM_API, STORED_CARDS } from './data';
import StoredCardsStore from './../store';

describe( 'Stored Cards Store', () => {
describe( 'store', () => {
it( 'should be an object', () => {
expect( StoredCardsStore ).to.be.an( 'object' );
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import moment from 'moment';
*/
import { createPurchasesArray } from '../assembler';

describe( 'Purchases assembler', () => {
describe( 'assembler', () => {
it( 'should be a function', () => {
expect( createPurchasesArray ).to.be.an( 'function' );
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ import {
DOMAIN_MAPPING_PURCHASE_EXPIRED,
SITE_REDIRECT_PURCHASE,
SITE_REDIRECT_PURCHASE_EXPIRED
} from 'data';
} from './data';
import { isRemovable } from '../index';

describe( 'Purchases Utils', () => {
describe( 'isRemovable', () => {
describe( 'index', () => {
describe( '#isRemovable', () => {
it( 'should not be removable when domain registration purchase is not expired', () => {
expect( isRemovable( DOMAIN_PURCHASE ) ).to.be.false;
} );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import defer from 'lodash/defer';
import { action as actionTypes } from 'lib/upgrades/constants';
import PurchasesStore from '../store';

describe( 'Purchases Store', () => {
describe( 'store', () => {
const userId = 1337,
siteId = 2701;

Expand Down
6 changes: 6 additions & 0 deletions client/test/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,12 @@
"posts": {
"test": [ "actions", "post-edit-store", "post-list-store", "utils" ]
},
"purchases": {
"stored-cards": {
"test": [ "assembler", "store" ]
},
"test": [ "assembler", "index", "store" ]
},
"store": {
"test": [ "index-test" ]
}
Expand Down

0 comments on commit f2479aa

Please sign in to comment.