duanjiaren8188 2015-07-23 17:14
浏览 60

Eclipse中的PHPUnit无法从现有类创建测试用例

I have installed PTI plugin in my Eclipse Luna in order to use PHPUnit. Whenever I try to create a test case from a existing php class (right click over the php file -> New -> New PHPUnit Test case) the dialog doesn't work (the "Finish" button seems to do nothing):

enter image description here

After checking the Eclipse log I found this error:

org.eclipse.ui Error Thu Jul 23 19:09:39 CEST 2015 Unhandled event loop exception

java.lang.NoSuchMethodError: org.eclipse.php.internal.debug.core.preferences.PHPDebuggersRegistry.getDebuggerConfiguration(Ljava/lang/String;)Lorg/eclipse/php/internal/debug/core/debugger/AbstractDebuggerConfiguration; at org.phpsrc.eclipse.pti.core.launching.PHPToolLauncher.createConfiguration(PHPToolLauncher.java:376) at org.phpsrc.eclipse.pti.core.launching.PHPToolLauncher.findLaunchConfiguration(PHPToolLauncher.java:265) at org.phpsrc.eclipse.pti.core.launching.PHPToolLauncher.launch(PHPToolLauncher.java:136) at org.phpsrc.eclipse.pti.core.launching.PHPToolLauncher.launch(PHPToolLauncher.java:117) at org.phpsrc.eclipse.pti.tools.phpunit.core.PHPUnit.createSkeleton(PHPUnit.java:178) at org.phpsrc.eclipse.pti.tools.phpunit.core.PHPUnit.createTestSkeleton(PHPUnit.java:131) at org.phpsrc.eclipse.pti.tools.phpunit.core.PHPUnitUtil.syncPHPClassToTestCase(PHPUnitUtil.java:174) at org.phpsrc.eclipse.pti.tools.phpunit.ui.wizards.CreatePHPUnitTestCaseWizard.performFinish(CreatePHPUnitTestCaseWizard.java:33) at org.eclipse.jface.wizard.WizardDialog.finishPressed(WizardDialog.java:853) at org.eclipse.jface.wizard.WizardDialog.buttonPressed(WizardDialog.java:438) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:619) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:248) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4454) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1388) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3799) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3409) at org.eclipse.jface.window.Window.runEventLoop(Window.java:832) at org.eclipse.jface.window.Window.open(Window.java:808) at org.eclipse.ui.internal.actions.NewWizardShortcutAction.run(NewWizardShortcutAction.java:136) at org.eclipse.jface.action.Action.runWithEvent(Action.java:519) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:595) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:511) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:420) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84) at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4454) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1388) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3799) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3409) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1151) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1032) at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148) at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:636) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:579) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:135) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603) at org.eclipse.equinox.launcher.Main.run(Main.java:1465) at org.eclipse.equinox.launcher.Main.main(Main.java:1438)

Any help would be appreciated. Thank you very much.

  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥15 Python3.5 相关代码写作
    • ¥20 测距传感器数据手册i2c
    • ¥15 RPA正常跑,cmd输入cookies跑不出来
    • ¥15 求帮我调试一下freefem代码
    • ¥15 matlab代码解决,怎么运行
    • ¥15 R语言Rstudio突然无法启动
    • ¥15 关于#matlab#的问题:提取2个图像的变量作为另外一个图像像元的移动量,计算新的位置创建新的图像并提取第二个图像的变量到新的图像
    • ¥15 改算法,照着压缩包里边,参考其他代码封装的格式 写到main函数里
    • ¥15 用windows做服务的同志有吗
    • ¥60 求一个简单的网页(标签-安全|关键词-上传)