Skip to content

Commit

Permalink
test(AutoControlledComponent): silence logs
Browse files Browse the repository at this point in the history
  • Loading branch information
levithomason committed May 24, 2016
1 parent bd0e7be commit 3cdacd3
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions test/specs/utils/AutoControlledComponent-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ describe('extending AutoControlledComponent', () => {
})

it('sets state for autoControlledProps', () => {
consoleUtil.disableOnce()

const autoControlledProps = _.keys(makeProps())
const randomProp = _.sample(autoControlledProps)
const randomValue = faker.hacker.verb()
Expand Down Expand Up @@ -70,6 +72,8 @@ describe('extending AutoControlledComponent', () => {
})

it('does not set state for props defined by the parent', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)

Expand All @@ -95,6 +99,8 @@ describe('extending AutoControlledComponent', () => {

describe('initial state', () => {
it('is derived from autoControlledProps in props', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)

Expand All @@ -114,6 +120,8 @@ describe('extending AutoControlledComponent', () => {

describe('default props', () => {
it('are applied to state for props in autoControlledProps', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)
const defaultProps = makeDefaultProps(props)
Expand All @@ -134,6 +142,8 @@ describe('extending AutoControlledComponent', () => {
})

it('allows trySetState to work on non-default autoControlledProps', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)
const defaultProps = makeDefaultProps(props)
Expand All @@ -155,6 +165,8 @@ describe('extending AutoControlledComponent', () => {

describe('changing props', () => {
it('sets state for props in autoControlledProps', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)

Expand Down Expand Up @@ -189,6 +201,8 @@ describe('extending AutoControlledComponent', () => {
})

it('does not set state for default props when changed', () => {
consoleUtil.disableOnce()

const props = makeProps()
const autoControlledProps = _.keys(props)
const defaultProps = makeDefaultProps(props)
Expand Down

0 comments on commit 3cdacd3

Please sign in to comment.