Skip to content

Fix xml tests that broke with mime update - #1227

Merged
kornelski merged 1 commit into
forwardemail:masterfrom
focusaurus:fix-latest-mime-tests
May 24, 2017
Merged

Fix xml tests that broke with mime update#1227
kornelski merged 1 commit into
forwardemail:masterfrom
focusaurus:fix-latest-mime-tests

Conversation

@focusaurus

Copy link
Copy Markdown
Contributor

No description provided.

@focusaurus
focusaurus force-pushed the fix-latest-mime-tests branch from c0b3391 to 0173a9d Compare May 15, 2017 17:43
@focusaurus

Copy link
Copy Markdown
Contributor Author

Looks like mime 1.3.4 had xml as application/xml and by 1.3.6 it switched to text/xml. I don't know the backstory behind that nor am I sure of what the semver/breakage implication is for end users of superagent.

PWesterdale pushed a commit to PWesterdale/superagent that referenced this pull request May 18, 2017
@focusaurus

Copy link
Copy Markdown
Contributor Author

@pornel Thoughts on this?

I confirmed it was mime 1.3.6 that introduced this change.

/tmp/20170524-100433 -> npm i mime@1.3.5
mime@1.3.5 node_modules/mime
/tmp/20170524-100433 -> node
> require('mime').types.xml
'application/xml'

/tmp/20170524-100433 -> npm i mime@1.3.6
mime@1.3.6 node_modules/mime
/tmp/20170524-100433 -> node
> require('mime').types.xml
'text/xml'

I did some github research trying to understand the back story for this change but the rabbit hole got the best of me.

@focusaurus

Copy link
Copy Markdown
Contributor Author

Also FYI I asked for help here: broofa/mime#158

I see no mention of this change in the mime-db history file: https://github.com/jshttp/mime-db/blob/master/HISTORY.md

I'm a bit perplexed at this point. Hopefully someone closer to the issue might shed some light so we can merge this and get the tests passing again.

@kornelski
kornelski merged commit d0ab622 into forwardemail:master May 24, 2017
kornelski added a commit that referenced this pull request Aug 8, 2017
* commit '4e21f1c509c3ee09ea4031c27855ed8e9ddc0d35':
  Documented FormData support in .send() (#1260)
  Update supported node version to >= 4.0 (#1248)
  Keep nodelay always on
  support TCP_NODELAY option (#1240)
  timeout options.read property is not used.
  grammar misstype (#1234)
  Fix spelling mistake in the docs (#1232)
  Revert test 'fixes' - see PR #1227
  Support passphrase with pfx certificate
  Fix build errors
  Send payload in query string for GET and HEAD shorthand API
  Fix xml tests that broke with mime update
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants