【问题标题】:Can Appium automate mobile apps build on Titanium Appcelerator?Appium 能否在 Titanium Appcelerator 上自动化移动应用程序?
【发布时间】:2017-05-10 09:54:03
【问题描述】:

我正在尝试使用 Titanium Appcelerator 自动构建应用程序。 当我使用 UIAutomator 检查元素时,我无法找到资源 ID。我使用路径作为解决方法,但这不是长期解决方案。

有没有人使用过 Appcelerator 和 Appium 并且能够帮助我?

【问题讨论】:

    标签: titanium appium titanium-mobile appcelerator-titanium appcelerator-mobile


    【解决方案1】:

    绝对可以将 Appium 与 A​​ppcelerator Titanium 一起使用!关键是在您的视图上使用accessibilityLabel 属性。

    <Label id="label1" accessibilityLabel="label1" text="I am label1" />

    然后你可以在你的 Appium 测试中做这样的事情:

    it('should have label1', function() {
        return driver
            .elementByAccessibilityId('label1')
            .should.eventually.exist
            .getAttribute('value')
            .should.become('I am label1');
    });
    

    如果您对此有任何疑问,请告诉我!我可能会一起blog post about it here,因为我知道很多其他开发人员也有同样的问题。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-10-10
      • 1970-01-01
      • 2020-10-05
      • 2021-10-11
      • 2021-08-04
      相关资源
      最近更新 更多