Skip to content

Commit

Permalink
fix: rename files and class
Browse files Browse the repository at this point in the history
  • Loading branch information
adelkahomolova committed Nov 18, 2019
1 parent 51b7460 commit dbd4cb0
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
import { PracticeEvaluationResult } from '../../model';
import { DependenciesVersionPractice } from './DependenciesVersionPractice';
import { DependenciesVersionMajorLevel } from './DependenciesVersionMajorLevel';
import { createTestContainer, TestContainerContext } from '../../inversify.config';
import ncu from 'npm-check-updates';
import { JavaScriptPackageInspector } from '../../inspectors/package/JavaScriptPackageInspector';
import { mockPackage } from '../../../test/helpers/mockPackage';
jest.mock('npm-check-updates');

describe('DependenciesVersionPractice of Major Level', () => {
let practice: DependenciesVersionPractice;
let practice: DependenciesVersionMajorLevel;
let containerCtx: TestContainerContext;
const mockedNcu = <jest.Mock>ncu.run;
const MockedJSPackageInspector = <jest.Mock<JavaScriptPackageInspector>>(<unknown>JavaScriptPackageInspector);
let mockJsPackageInspector: JavaScriptPackageInspector;

beforeAll(async () => {
containerCtx = createTestContainer();
containerCtx.container.bind('DependenciesVersionPractice').to(DependenciesVersionPractice);
containerCtx.container.bind('DependenciesVersionPractice').to(DependenciesVersionMajorLevel);
practice = containerCtx.container.get('DependenciesVersionPractice');
mockJsPackageInspector = new MockedJSPackageInspector();
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { IPractice } from '../IPractice';
reportOnlyOnce: true,
url: 'https://renovatebot.com/',
})
export class DependenciesVersionPractice implements IPractice {
export class DependenciesVersionMajorLevel implements IPractice {
async isApplicable(ctx: PracticeContext): Promise<boolean> {
return (
ctx.projectComponent.language === ProgrammingLanguage.JavaScript || ctx.projectComponent.language === ProgrammingLanguage.TypeScript
Expand Down
4 changes: 2 additions & 2 deletions src/practices/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import { EditorConfigIsPresentPractice } from './LanguageIndependent/EditorConfi
import { GitignoreIsPresentPractice } from './LanguageIndependent/GitignoreIsPresentPractice';
import { JsGitignoreCorrectlySetPractice } from './JavaScript/JsGitignoreCorrectlySetPractice';
import { JavaGitignoreCorrectlySetPractice } from './Java/JavaGitignoreCorrectlySetPractice';
import { DependenciesVersionPractice } from './JavaScript/DependenciesVersionPractice';
import { DependenciesVersionMajorLevel } from './JavaScript/DependenciesVersionMajorLevel';
import { ESLintWithoutErrorsPractice } from './JavaScript/ESLintWithoutErrorsPractice';
import { TsGitignoreCorrectlySetPractice } from './TypeScript/TsGitignoreCorrectlySetPractice';

Expand All @@ -40,7 +40,7 @@ export const practices = [
DeprecatedTSLintPractice,
DockerizationUsedPractice,
EditorConfigIsPresentPractice,
DependenciesVersionPractice,
DependenciesVersionMajorLevel,
GitignoreIsPresentPractice,
JsGitignoreCorrectlySetPractice,
JavaGitignoreCorrectlySetPractice,
Expand Down

0 comments on commit dbd4cb0

Please sign in to comment.