I am trying to run test using appium-flutter-driver. Getting following error

Error: Failed to create session. All non-standard capabilities should have a vendor prefix. The following capabilities did not have one: 0

enter image description here

package.json

{
  "scripts": {
    "android": "wdio ./config/wdio.android.conf.ts",
    "test:ios": "PLATFORM=iOS npx wdio run ./config/wdio.ios.conf.ts"
  },
  "dependencies": {
    "@wdio/cli": "^8.27.2",
    "@wdio/jasmine-framework": "^8.27.2",
    "appium-flutter-finder": "^0.2.0",
    "appium-version-manager": "^0.1.2"
  },
  "devDependencies": {
    "@types/chai": "^4.3.11",
    "@wdio/appium-service": "^8.27.2",
    "@wdio/local-runner": "^8.27.2",
    "@wdio/mocha-framework": "^8.27.2",
    "@wdio/spec-reporter": "^8.27.2",
    "chai": "^5.0.0",
    "ts-node": "^10.9.2",
    "typescript": "^5.3.3",
    "webdriverio": "^8.27.2"
  }
}

wdio.android.conf.ts

import { join } from 'path';
export const config = {
    runner: 'local',
    port: 4723,
    specs: [
        '../test/specs/*.ts'
    ],
    exclude: [
        // 'path/to/excluded/files'
    ],
    maxInstances: 10,
    capabilities: [{
        "appium:platformName": "Android",
        "appium:deviceName": "Pixel 6",
        "appium:avd": "Pixel_6",
        "appium:automationName": "Flutter",
        "appium:version": "11",
        "appium:app": join(process.cwd(), "build/app-debug.apk"),
    }],
    logLevel: 'info',
    bail: 0,
    // baseUrl: 'http://localhost',
    waitforTimeout: 10000,
    connectionRetryTimeout: 130000,
    connectionRetryCount: 1,
    services: [
        ['appium', {
            command: 'appium',
            address: 'localhost',
            sessionOverride: true,
            basePath: '/wd/hub',
        }]
    ],
    framework: 'jasmine',
    reporters: ['spec'],
    mochaOpts: {
        ui: 'bdd',
        timeout: 6000
    },
}

example.e2e.ts

import {config} from "../../config/wdio.android.conf";
const wdio = require('webdriverio');

describe('Counter', () => {
    it('Purchase Increment', async () => {

      await console.log('hello');

      const driver = await wdio.remote(config);

      // const a = driver.byText('Update Now');
      // await driver.elementClick(a);

      // const b = a.getElementText();

      // await console.log("element text: " + b)

      // const value = await(await(await(await(await(await(await new HomeScreen()
      // .add())
      // .addDetails(random_mobile(),random_email()))
      // .selectCardAsPaymentMethod())
      // .pay('41111111111111111','1122','Atmaram Naik','111'))
      // .makeSuccessful())
      // .waitForPaymentSuccess())
      // .getCounter()
      // expect(value).to.be.eq('1')
    });
});

I attempted various approaches, including adding prefixes to the capabilities and removing them, but none of these assumptions yielded the desired results.

0

There are 0 best solutions below