<commit_before># TOC
   - [#acceptable](#acceptable)
<a name=""></a>
 
<a name="acceptable"></a>
# #acceptable
should accept an argument list of extensions.

```js
var test;
test = acceptable('json', 'txt', 'html', 'jpeg', 'xml');
unit["function"](test);
return null;
```

should accept an array of extensions.

```js
var test;
test = acceptable(['json', 'txt', 'html', 'jpeg', 'xml']);
unit["function"](test);
return null;
```

should accept an argument list of mime types.

```js
var test;
test = acceptable('application/json', 'application/javascript', 'text/plain');
unit["function"](test);
return null;
```

should accept an array of mime types.

```js
var test;
test = acceptable(['application/json', 'application/javascript', 'text/plain']);
unit["function"](test);
return null;
```

should accept an argument list of extensions or mime types.

```js
var test;
test = acceptable('json', 'application/js', 'xml', 'text/plain');
unit["function"](test);
return null;
```

should accept an array of extensions or mime types.

```js
var test;
test = acceptable(['json', 'application/js', 'xml', 'text/plain']);
unit["function"](test);
return null;
```

should accept an argument list that contain arrays.

```js
var test;
test = acceptable('js', ['application/json', 'xml'], 'text/plain');
unit["function"](test);
return null;
```

should throw an error if any argument is not a string or array of strings.

```js
unit.error(function() {
  return acceptable(5);
}).error(function() {
  return acceptable([5]);
}).error(function() {
  return acceptable('js', 9);
}).error(function() {
  return acceptable(['js', 9]);
}).error(function() {
  return accpetable(false);
}).error(function() {
  return acceptable(/.*/);
}).error(function() {
  return acceptable(_.noop);
}).error(function() {
  return acceptable({});
});
return null;
```

should preform content negotiation.

```js
unit.httpAgent(app).get('/test').set('Accept', 'application/json').expect(200).end(function(err, res) {
  return !res.body;
});
unit.httpAgent(app).get('/test').set('Accept', 'application/xml').expect(406).end(done);
return null;
```
<commit_msg>update TEST.md to current tests<commit_after># TOC
   - [#acceptable](#acceptable)
<a name=""></a>
 
<a name="acceptable"></a>
# #acceptable
should accept an argument list of extensions.

```js
var test;
test = acceptable('json', 'txt', 'html', 'jpeg', 'xml');
unit.function(test);
return null;
```

should accept an array of extensions.

```js
var test;
test = acceptable(['json', 'txt', 'html', 'jpeg', 'xml']);
unit.function(test);
return null;
```

should accept an argument list of mime types.

```js
var test;
test = acceptable('application/json', 'application/javascript', 'text/plain');
unit.function(test);
return null;
```

should accept an array of mime types.

```js
var test;
test = acceptable(['application/json', 'application/javascript', 'text/plain']);
unit.function(test);
return null;
```

should accept an argument list of extensions or mime types.

```js
var test;
test = acceptable('json', 'application/js', 'xml', 'text/plain');
unit.function(test);
return null;
```

should accept an array of extensions or mime types.

```js
var test;
test = acceptable(['json', 'application/js', 'xml', 'text/plain']);
unit.function(test);
return null;
```

should accept an argument list that contain arrays.

```js
var test;
test = acceptable('js', ['application/json', 'xml'], 'text/plain');
unit.function(test);
return null;
```

should throw an error if any argument is not a string or array of strings.

```js
unit.error(function() {
  return acceptable(5);
}).error(function() {
  return acceptable([5]);
}).error(function() {
  return acceptable('js', 9);
}).error(function() {
  return acceptable(['js', 9]);
}).error(function() {
  return accpetable(false);
}).error(function() {
  return acceptable(/.*/);
}).error(function() {
  return acceptable(_.noop);
}).error(function() {
  return acceptable({});
});
return null;
```

should respond with 200 for acceptable content negotiation.

```js
unit.httpAgent(app).get('/test').set('Accept', 'application/json').expect(200).end(done);
return null;
```

should respond with 406 for unacceptable content negotiation.

```js
unit.httpAgent(app).get('/test').set('Accept', 'application/xml').expect(406).end(done);
return null;
```

{'fraction_non_alphanumeric': 0.1980564553447478, 'fraction_numerical': 0.006015733456732994, 'mean_word_length': 5.55, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 12}, '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': '6823144', 'n_tokens_mistral': 1397, 'n_tokens_neox': 1312, 'n_words': 412}