summaryrefslogtreecommitdiff
path: root/jstests/noPassthrough/shell_check_program_extension.js
blob: c8932b212c546b271913f98f92635b7b0f3365a8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
/**
 * Tests that the shell correctly checks for program extensions in Windows environments.
 */

(function() {
    'use strict';

    if (_isWindows()) {
        const filename = 'jstests/noPassthrough/libs/testWindowsExtension.bat';

        clearRawMongoProgramOutput();
        const result = runMongoProgram(filename);
        assert.eq(result, 42);
    } else {
        jsTestLog("This test is only relevant for Windows environments.");
    }
})();