Skip to content

Commit

Permalink
Add unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
laysent committed Jun 1, 2017
1 parent 5fd356d commit ac3d76a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/src/core/resolve.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { expect } from 'chai'
import resolve, { CASE_SENSITIVE_FS, fileExistsWithCaseSync } from 'eslint-module-utils/resolve'
import ModuleCache from 'eslint-module-utils/ModuleCache'

import * as path from 'path'
import * as fs from 'fs'
import * as utils from '../utils'

Expand Down Expand Up @@ -43,6 +44,11 @@ describe('resolve', function () {
expect(fileExistsWithCaseSync(file, ModuleCache.getSettings(testContext)))
.to.be.false
})
it('detecting case does not include parent folder path (issue #720)', function () {
const f = path.join(process.cwd().toUpperCase(), './tests/files/jsx/MyUnCoolComponent.jsx')
expect(fileExistsWithCaseSync(f, ModuleCache.getSettings(testContext), true))
.to.be.true
})
})

describe('rename cache correctness', function () {
Expand Down

0 comments on commit ac3d76a

Please sign in to comment.