Skip to content
This repository has been archived by the owner on Mar 9, 2021. It is now read-only.

Commit

Permalink
Restructure test case
Browse files Browse the repository at this point in the history
Add another describe block around it to group the following test case with it.
  • Loading branch information
hpurmann committed Aug 8, 2016
1 parent 1f80880 commit 3bff301
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions test/set-items.ut.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,19 @@ import { iterable, expectExactlySameMembers } from './helper'


describe('setItems - updating the list of selectable items', () => {
it('should remove items from selection that don\'t exist anymore', () => {
const state = init()
describe('remove selected items', () => {
it('should remove items from selection that don\'t exist anymore', () => {
const state = init()

const newState = flow(
setItems(iterable(['A', 'B', 'C', 'D'])),
setSelection(['B', 'C']),
setItems(iterable(['A', 'C', 'D']))
)(state)
const newState = flow(
setItems(iterable(['A', 'B', 'C', 'D'])),
setSelection(['B', 'C']),
setItems(iterable(['A', 'C', 'D']))
)(state)

expectExactlySameMembers(getSelection(newState), ['C'])
})

expectExactlySameMembers(getSelection(newState), ['C'])
})

it('should remove item from anchor that doesn\'t exist anymore', () => {
Expand Down

0 comments on commit 3bff301

Please sign in to comment.