<commit_before># component-mock

> A wrapper for deku components to facilitate easier unit-testing.

## Usage

```js
var mock = require('component-mock');

var Component = {
  defaultProps: {
    name: 'a'
  },
  render: function ({ props }) {
    return <div>{props.name}</div>;
  }
}

var mock = Mock(Component);

var node = mock.render();
assert.isNode(node, 'div');
assert.hasChildren(node, [ 'a' ]);

var node = mock.render({ props: { name: 'b' } });
assert.isNode(node, 'div');
assert.hasChildren(node, [ 'b' ]);
```
<commit_msg>Fix require assignment in example<commit_after># component-mock

> A wrapper for deku components to facilitate easier unit-testing.

## Usage

```js
var Mock = require('component-mock');

var Component = {
  defaultProps: {
    name: 'a'
  },
  render: function ({ props }) {
    return <div>{props.name}</div>;
  }
}

var mock = Mock(Component);

var node = mock.render();
assert.isNode(node, 'div');
assert.hasChildren(node, [ 'a' ]);

var node = mock.render({ props: { name: 'b' } });
assert.isNode(node, 'div');
assert.hasChildren(node, [ 'b' ]);
```

{'fraction_non_alphanumeric': 0.1889908256880734, 'fraction_numerical': 0.0, 'mean_word_length': 4.122065727699531, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1705337', 'n_tokens_mistral': 379, 'n_tokens_neox': 372, 'n_words': 96}