|
Currently, we parse the programMajorMinorVersion like so in servers.js.
An example would be that for a binary like 'mongo-4.4', we end up parsing programMajorMinorVersion to be '404'.
There are currently usages of the variable that expect a different parsing convention. For instance, this line here expects a binary like 'mongo-4.3' to have programMajorMinorVersion = '430'. This becomes a problem for our multiversion tests since this means we aren't getting the test coverage that we expect.
Another example of an incorrect usage can be found here.
It seems a little unintuitive that we parse the programMajorMinorVersion to be '404' rather than '440'. Maybe we should consider updating programMajorMinorVersion to be the following:
programMajorMinorVersion = parseInt(major) * 100 + parseInt(minor) * 10;
|
At the very least, we should fix the conditionals that are checking for programMajorMinorVersion incorrectly to get the intended test coverage in our multiversion tests.
|