Browser-compat-data: JSON linter: don't allow version_added === version_removed

Created on 26 Feb 2019  路  6Comments  路  Source: mdn/browser-compat-data

We have a couple of places here and there where version_added is invalidly the same as version_removed; we need to update the linter to catch this.

linter

Most helpful comment

I just submitted a PR that will fix them, but RTCPeerConnection.onaddstream has this problem, for instance:

https://github.com/mdn/browser-compat-data/blob/master/api/RTCPeerConnection.json#L1999

All 6 comments

Would you mind sharing a couple of these examples?

I just submitted a PR that will fix them, but RTCPeerConnection.onaddstream has this problem, for instance:

https://github.com/mdn/browser-compat-data/blob/master/api/RTCPeerConnection.json#L1999

+1 for this. Having a feature removed in the same version it was introduced in doesn鈥檛 make any sense!

I thought this would be checked here https://github.com/mdn/browser-compat-data/blob/master/test/test-versions.js#L51

But maybe it is suitable to test this in the consistency tests as well. I haven't reviewed it yet.

The test should be compareVersions(a, b) >= 0.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ghost picture ghost  路  3Comments

vinyldarkscratch picture vinyldarkscratch  路  3Comments

dontcallmedom picture dontcallmedom  路  4Comments

vinyldarkscratch picture vinyldarkscratch  路  3Comments

ddbeck picture ddbeck  路  3Comments