Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
254,500 | void () { executeAction(IdeActions.ACTION_EDITOR_PASTE); } | paste |
254,501 | void () { executeAction(IdeActions.ACTION_EDITOR_PREVIOUS_WORD_WITH_SELECTION); } | moveCaretToPreviousWordWithSelection |
254,502 | void () { executeAction(IdeActions.ACTION_EDITOR_NEXT_WORD_WITH_SELECTION); } | moveCaretToNextWordWithSelection |
254,503 | void () { executeAction(IdeActions.ACTION_EDITOR_PREVIOUS_WORD); } | previousWord |
254,504 | void () { executeAction(IdeActions.ACTION_EDITOR_NEXT_WORD); } | nextWord |
254,505 | void () { executeAction("EditorCutLineBackward"); } | cutLineBackward |
254,506 | void () { executeAction("EditorCutLineEnd"); } | cutToLineEnd |
254,507 | void () { executeAction("EditorDeleteToLineStart"); } | deleteToLineStart |
254,508 | void () { executeAction("EditorDeleteToLineEnd"); } | deleteToLineEnd |
254,509 | void () { executeAction("EditorKillToWordStart"); } | killToWordStart |
254,510 | void () { executeAction("EditorKillToWordEnd"); } | killToWordEnd |
254,511 | void () { executeAction("EditorKillRegion"); } | killRegion |
254,512 | void () { executeAction("EditorKillRingSave"); } | killRingSave |
254,513 | void () { executeAction("EditorUnindentSelection"); } | unindent |
254,514 | void () { executeAction("EditorSelectLine"); } | selectLine |
254,515 | void () { executeAction("EditorLeft"); } | left |
254,516 | void () { executeAction("EditorRight"); } | right |
254,517 | void () { executeAction("EditorLeftWithSelection"); } | leftWithSelection |
254,518 | void () { executeAction("EditorRightWithSelection"); } | rightWithSelection |
254,519 | void () { executeAction("EditorUp"); } | up |
254,520 | void () { executeAction("EditorDown"); } | down |
254,521 | void () { executeAction(IdeActions.ACTION_EDITOR_MOVE_CARET_UP_WITH_SELECTION); } | upWithSelection |
254,522 | void () { executeAction(IdeActions.ACTION_EDITOR_MOVE_CARET_DOWN_WITH_SELECTION); } | downWithSelection |
254,523 | void () { executeAction(IdeActions.ACTION_COMMENT_LINE); } | lineComment |
254,524 | void (@NonNls @NotNull String actionId) { executeAction(actionId, getEditor()); } | executeAction |
254,525 | void (@NonNls @NotNull String actionId, @NotNull Editor editor) { executeAction(actionId, editor, getProject()); } | executeAction |
254,526 | void (@NonNls @NotNull String actionId, @NotNull Editor editor, @Nullable Project project) { CommandProcessor.getInstance() .executeCommand(project, () -> EditorTestUtil.executeAction(editor, actionId, true), "", null, editor.getDocument()); } | executeAction |
254,527 | DataContext () { DataContext defaultContext = DataManager.getInstance().getDataContext(); return CustomizedDataContext.create(defaultContext, dataId -> { if (CommonDataKeys.EDITOR.is(dataId)) { return getEditor(); } if (CommonDataKeys.PROJECT.is(dataId)) { return getProject(); } if (CommonDataKeys.PSI_FILE.is(dataId)) ... | getCurrentEditorDataContext |
254,528 | List<Object[]> () { return Collections.emptyList(); } | params |
254,529 | String () { if (myFileSuffix != null) { return "test" + myFileSuffix; } return super.getName(); } | getName |
254,530 | void (@NotNull Editor editor) { myEditor = editor; } | setEditor |
254,531 | void (@NotNull PsiFile file) { myFile = file; } | setFile |
254,532 | void (@NotNull VirtualFile virtualFile) { myVFile = virtualFile; } | setVFile |
254,533 | void (@NotNull IndexingMode mode) { myIndexingMode = mode; } | setIndexingMode |
254,534 | IndexingMode () { return myIndexingMode; } | getIndexingMode |
254,535 | boolean (@NotNull VirtualFile file) { if (file instanceof VirtualFileWindow) return false; if (myAddedClasses.contains(file) || myTreeAccessAllowed) return false; FileType fileType = file.getFileType(); return (fileType == StdFileTypes.JAVA || fileType == StdFileTypes.CLASS) && !file.getName().equals("package-info.java... | accept |
254,536 | void (@NotNull VirtualFile file) { myAddedClasses.add(file); } | allowTreeAccessForFile |
254,537 | void () { myTreeAccessAllowed = true; } | allowTreeAccessForAllFiles |
254,538 | String () { return "JAVA {allowed=" + myTreeAccessAllowed + " files=" + new ArrayList<>(myAddedClasses) + "}"; } | toString |
254,539 | void () { CodeStyleSettings oldSettings = myOldSettings; if (oldSettings == null) { return; } myOldSettings = null; UsefulTestCase.doCheckForSettingsDamage(oldSettings, myCurrentSettingsSupplier.get()); } | checkForSettingsDamage |
254,540 | HighlightTestInfo () { checkWarnings = true; return this; } | checkWarnings |
254,541 | HighlightTestInfo () { checkWeakWarnings = true; return this; } | checkWeakWarnings |
254,542 | HighlightTestInfo () { checkInfos = true; return this; } | checkInfos |
254,543 | HighlightTestInfo () { checkSymbolNames = true; return this; } | checkSymbolNames |
254,544 | HighlightTestInfo (@NonNls @NotNull String root) { projectRoot = root; return this; } | projectRoot |
254,545 | HighlightTestInfo () { try { doTest(); return this; } finally { tested = true; Disposer.dispose(this); } } | test |
254,546 | void () { assert tested : "You must call HighlightTestInfo.test() in " + myPlace; } | dispose |
254,547 | Project () { return ourProject; } | getProject |
254,548 | Module () { return ourModule; } | getModule |
254,549 | PsiManager () { if (ourPsiManager == null) { ourPsiManager = PsiManager.getInstance(getProject()); } return ourPsiManager; } | getPsiManager |
254,550 | TestApplicationManager () { return TestApplicationManager.getInstanceIfCreated(); } | getApplication |
254,551 | void () { System.out.println("----- TEST STATISTICS -----"); UsefulTestCase.logSetupTeardownCosts(); System.out.printf("##teamcity[buildStatisticValue key='ideaTests.appInstancesCreated' value='%d']%n", MockApplication.INSTANCES_CREATED); System.out.printf("##teamcity[buildStatisticValue key='ideaTests.projectInstances... | reportTestExecutionStatistics |
254,552 | void () { resetClassFields(getClass()); } | resetAllFields |
254,553 | void (@NotNull Class<?> aClass) { try { UsefulTestCase.clearDeclaredFields(this, aClass); } catch (IllegalAccessException e) { throw new RuntimeException(e); } if (aClass == LightPlatformTestCase.class) return; resetClassFields(aClass.getSuperclass()); } | resetClassFields |
254,554 | void () { ((PersistentFSImpl)PersistentFS.getInstance()).cleanPersistedContents(); } | cleanPersistedVFSContent |
254,555 | void (@NotNull LightProjectDescriptor descriptor) { ourProjectDescriptor = descriptor; if (ourProject != null) { closeAndDeleteProject(); } ApplicationManager.getApplication().runWriteAction(() -> cleanPersistedVFSContent()); Path tempDirectory = TemporaryDirectory.generateTemporaryPath(ProjectImpl.LIGHT_PROJECT_NAME +... | initProject |
254,556 | void (@NotNull Module module) { //noinspection AssignmentToStaticFieldFromInstanceMethod ourModule = module; } | moduleCreated |
254,557 | void (@NotNull VirtualFile sourceRoot) { //noinspection AssignmentToStaticFieldFromInstanceMethod ourSourceRoot = sourceRoot; } | sourceRootCreated |
254,558 | VirtualFile () { return ourSourceRoot; } | getSourceRoot |
254,559 | LightProjectDescriptor () { return new SimpleLightProjectDescriptor(getModuleTypeId(), getProjectJDK()); } | getProjectDescriptor |
254,560 | void (@NotNull Project project, @NotNull Module module) { fail("Adding modules is not permitted in light tests."); } | moduleAdded |
254,561 | void (InspectionProfileEntry @NotNull ... tools) { InspectionsKt.enableInspectionTools(getProject(), getTestRootDisposable(), tools); } | enableInspectionTools |
254,562 | void (@NotNull InspectionToolWrapper<?,?> toolWrapper) { InspectionsKt.enableInspectionTool(getProject(), toolWrapper, getTestRootDisposable()); } | enableInspectionTool |
254,563 | void (@NotNull InspectionProfileEntry tool) { InspectionsKt.enableInspectionTool(getProject(), tool, getTestRootDisposable()); } | enableInspectionTool |
254,564 | void (@NotNull Project project) { WriteCommandAction.runWriteCommandAction(project, () -> { VirtualFile sourceRoot = getSourceRoot(); if (sourceRoot == null) { return; } for (VirtualFile child : sourceRoot.getChildren()) { try { child.delete(LightPlatformTestCase.class); } catch (IOException | IllegalStateException e) ... | tearDownSourceRoot |
254,565 | void () { TestApplicationKt.clearEncodingManagerDocumentQueue(ApplicationManager.getApplication()); } | clearEncodingManagerDocumentQueue |
254,566 | void (@NotNull Project project) { PsiDocumentManagerImpl documentManager = (PsiDocumentManagerImpl)PsiDocumentManager.getInstance(project); documentManager.clearUncommittedDocuments(); ProjectManagerEx projectManager = ProjectManagerEx.getInstanceEx(); if (projectManager.isDefaultProjectInitialized()) { Project default... | clearUncommittedDocuments |
254,567 | void () { // don't use method references here to make stack trace reading easier //noinspection Convert2MethodRef RunAll.runAll( () -> EDT.dispatchAllInvocationEvents(), () -> { // getAllEditors() should be called only after dispatchAllInvocationEvents(), that's why separate RunAll is used Application app = Application... | checkEditorsReleased |
254,568 | Object (@NotNull String dataId) { return getProject() == null || getProject().isDisposed() ? null : new TestDataProvider(getProject()).getData(dataId); } | getData |
254,569 | Sdk () { return null; } | getProjectJDK |
254,570 | String () { return EmptyModuleType.EMPTY_MODULE; } | getModuleTypeId |
254,571 | String (boolean lowercaseFirstLetter) { String name = getName(); name = StringUtil.trimStart(name, "test"); if (!name.isEmpty() && lowercaseFirstLetter && !PlatformTestUtil.isAllUppercaseName(name)) { name = Character.toLowerCase(name.charAt(0)) + name.substring(1); } return name; } | getTestName |
254,572 | CodeStyleSettings () { return CodeStyle.getSettings(getProject()); } | getCurrentCodeStyleSettings |
254,573 | CommonCodeStyleSettings (@NotNull Language language) { return getCurrentCodeStyleSettings().getCommonSettings(language); } | getLanguageSettings |
254,574 | void (@NotNull Document document) { PsiDocumentManager.getInstance(getProject()).commitDocument(document); } | commitDocument |
254,575 | void () { PsiDocumentManager.getInstance(getProject()).commitAllDocuments(); } | commitAllDocuments |
254,576 | Document (@NotNull PsiFile file) { return PsiDocumentManager.getInstance(getProject()).getDocument(file); } | getDocument |
254,577 | void (Project project) { ourProject = project; } | setProject |
254,578 | String () { return myModuleTypeId; } | getModuleTypeId |
254,579 | boolean (Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; SimpleLightProjectDescriptor that = (SimpleLightProjectDescriptor)o; if (!myModuleTypeId.equals(that.myModuleTypeId)) return false; return areJdksEqual(that.getSdk()); } | equals |
254,580 | int () { return myModuleTypeId.hashCode(); } | hashCode |
254,581 | boolean (Sdk newSdk) { if (mySdk == null || newSdk == null) return mySdk == newSdk; if (!mySdk.getName().equals(newSdk.getName())) return false; OrderRootType[] rootTypes = {OrderRootType.CLASSES, AnnotationOrderRootType.getInstance()}; for (OrderRootType rootType : rootTypes) { String[] myUrls = mySdk.getRootProvider(... | areJdksEqual |
254,582 | TreeNodeTester (TreeNode node) { return new TreeNodeTester(node); } | forNode |
254,583 | TreeNodeTester (Function<? super TreeNode, String> presenter) { myPresenter = presenter; return this; } | withPresenter |
254,584 | String () { StringBuilder buffer = new StringBuilder(); printSubTree(myNode, 0, buffer); return buffer.toString(); } | constructTextRepresentation |
254,585 | void (String expected) { Assert.assertEquals(expected, constructTextRepresentation()); } | assertStructureEquals |
254,586 | void (TreeNode node, int level, StringBuilder result) { result.append(" ".repeat(level)).append(myPresenter.apply(node)).append("\n"); for (int i = 0; i < node.getChildCount(); i++) { printSubTree(node.getChildAt(i), level+1, result); } } | printSubTree |
254,587 | void (final PsiFile psiFile, final PsiElement context) { if (context != null) { setFileContext(psiFile, SmartPointerManager.getInstance(context.getProject()).createSmartPsiElementPointer(context)); } } | setContext |
254,588 | void (PsiFile psiFile, @Nullable SmartPsiElementPointer<?> pointer) { psiFile.putUserData(FileContextUtil.INJECTED_IN_ELEMENT, pointer); } | setFileContext |
254,589 | VirtualFile (@NotNull String prefix) { return getVFileByFile(createTempFile(prefix)); } | createVFile |
254,590 | VirtualFile (@NotNull String prefix, String postfix) { return getVFileByFile(createTempFile(prefix, postfix)); } | createVFile |
254,591 | File (@NotNull String prefix) { return createTempFile(prefix, null); } | createTempFile |
254,592 | File (@NotNull String prefix, String suffix) { return createTempFile(prefix, suffix, true); } | createTempFile |
254,593 | File (@NotNull String prefix, String suffix, boolean isRefreshVfs) { try { File tempFile = FileUtilRt.createTempFile(prefix, suffix, false); tempFileCreated(tempFile.toPath()); if (isRefreshVfs) { getVFileByFile(tempFile); } return tempFile; } catch (IOException e) { throw new RuntimeException(e); } } | createTempFile |
254,594 | void (@NotNull Path tempFile) { myFilesToDelete.add(tempFile); } | tempFileCreated |
254,595 | VirtualFile (@NotNull File tempFile) { return LocalFileSystem.getInstance().refreshAndFindFileByIoFile(tempFile); } | getVFileByFile |
254,596 | File () { return createTempDir("dir"); } | createTempDir |
254,597 | File (@NotNull String prefix) { try { File dir = FileUtil.createTempDirectory(prefix, "test",false); tempFileCreated(dir.toPath()); HeavyPlatformTestCase.synchronizeTempDirVfs(getVFileByFile(dir)); return dir; } catch (IOException e) { throw new RuntimeException(e); } } | createTempDir |
254,598 | VirtualFile () { return createTempVDir("dir"); } | createTempVDir |
254,599 | VirtualFile (@NotNull String prefix) { return getVFileByFile(createTempDir(prefix)); } | createTempVDir |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.