pivotal/jasmine-ajax — pull request #72 by resident-uhlig (2014-07-13 01:43:09+00:00)
Title: Add support for multiple headers with same name

Currently you can only add one value per header name.
```javascript
jasmine.Ajax.requests.mostRecent().response({
status: 200,
responseHeaders: {
'X-Header': 'some value'
}
responseText: ""
});
```

You could try to add multiple values per header name using an array instead of a string, but this does not result in the expected behaviour.
```javascript
// ...
// returns as "X-Header: value1,value2" rather than "X-Header: value1\r\nX-Header: value2"
{ 'X-Header': ['value1', 'value2'] }
// ...
```

With this commit you can add multiple values per header name, in random order.
```javascript
// ....
{ responseHeaders: {
{ name: 'X-Header', value: 'value1' },
{ name: 'X-SomeOtherHeader', value: 'some other value' },
{ name: 'X-Header', value: 'value2' }
}}
// ...
```

This commit should be backward compatible. I have added some tests. I hope the code and the idea suits you.

Please note that I also changed some lines of code in order to satisfy jshint and in order to build the ruby dependencies on Windows.