Java 如何使用selenium启动Firefox32

Java 如何使用selenium启动Firefox32,java,selenium-webdriver,automation,Java,Selenium Webdriver,Automation,我需要启动Firefox32来启动遗留应用程序,但它抛出了错误“期望的功能不匹配”。这是我的密码 public void launchURL() throws Exception { WebDriverUtils utils = new WebDriverUtils(); this.driver = new WebDriverUtils().getWebDriver(); utils.visit(EnvironmentConfig.getInst

我需要启动Firefox32来启动遗留应用程序,但它抛出了错误“期望的功能不匹配”。这是我的密码

public void launchURL() throws Exception {

        WebDriverUtils utils = new WebDriverUtils();
        this.driver = new WebDriverUtils().getWebDriver();
        utils.visit(EnvironmentConfig.getInstance().getUrl());
        System.out.println("URL launched:" + EnvironmentConfig.getInstance().getUrl());
        Reporter.log("URL launched:" + EnvironmentConfig.getInstance().getUrl());

    }
控制台错误功能与使用webdriverutils启动firefox 32不匹配

org.openqa.selenium.SessionNotCreatedException: Unable to find a matching set of capabilities
Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:17:03'
System info: host: 'L-HDCFW643X2', ip: '192.168.114.65', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_221'
Driver info: driver.version: FirefoxDriver
remote stacktrace: 
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
    at org.openqa.selenium.remote.W3CHandshakeResponse.lambda$errorHandler$0(W3CHandshakeResponse.java:62)
    at org.openqa.selenium.remote.HandshakeResponse.lambda$getResponseFunction$0(HandshakeResponse.java:30)
    at org.openqa.selenium.remote.ProtocolHandshake.lambda$createSession$0(ProtocolHandshake.java:126)
    at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
    at java.util.Spliterators$ArraySpliterator.tryAdvance(Spliterators.java:958)
    at java.util.stream.ReferencePipeline.forEachWithCancel(ReferencePipeline.java:126)
    at java.util.stream.AbstractPipeline.copyIntoWithCancel(AbstractPipeline.java:499)
    at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:486)
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:472)
    at java.util.stream.FindOps$FindOp.evaluateSequential(FindOps.java:152)
    at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
    at java.util.stream.ReferencePipeline.findFirst(ReferencePipeline.java:464)
    at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:128)
    at org.openqa.selenium.remote.ProtocolHandshake.createSession(ProtocolHandshake.java:74)
    at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:136)
    at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:83)
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:552)
    at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:213)
    at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:131)
    at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:147)
    at com.gap.platform.seleniumwebdriverutils.LocalDriverFactory.createInstance(LocalDriverFactory.java:134)
    at org.gaptech.platform.cucumberutils.CucumberHooks.beforeScenarioStart(CucumberHooks.java:28)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at cucumber.runtime.Utils$1.call(Utils.java:26)
    at cucumber.runtime.Timeout.timeout(Timeout.java:16)
    at cucumber.runtime.Utils.invoke(Utils.java:20)
    at cucumber.runtime.java.JavaHookDefinition.execute(JavaHookDefinition.java:60)
    at cucumber.runner.HookDefinitionMatch.runStep(HookDefinitionMatch.java:16)
    at cucumber.runner.TestStep.executeStep(TestStep.java:65)
    at cucumber.runner.TestStep.run(TestStep.java:50)
    at cucumber.runner.TestCase.run(TestCase.java:42)
    at cucumber.runner.Runner.runPickle(Runner.java:49)
    at cucumber.runtime.Runtime$1.run(Runtime.java:82)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)
Jun 08, 2020 9:33:12 PM org.openqa.selenium.remote.DesiredCapabilities firefox
INFO: Using `new FirefoxOptions()` is preferred to `DesiredCapabilities.firefox()`

TestConfig:
   projectName: ABCD
   type: cucumber #(junit,runmanager,cucumber)  #no default value , must provide
   tags: '@OF' 
   execution: local #(remote ,local,docker) #defalut local
   environment: dev #dev qa prod e2e
   retryCount: 1
   webTest: true
   threadCount: 1
   splunkLogging: false
webDriverConfig:
   driver: firefox
   waitForTimeout: 10