【问题标题】:Fastlane passing parameters to pluginFastlane 将参数传递给插件
【发布时间】:2018-01-16 16:47:24
【问题描述】:

我正在使用 Fastlane 插件automated_test_emulator_run

automated_test_emulator_run(
    AVD_setup_path: "~/<path to your avd setup>/AVD_setup.json",
//some more tasks
  )

现在尝试通过命令行运行同样的操作

fastlane automated_test_emulator_run AVD_setup_path:avd.json

但是出错了

[!] 找不到“automated_test_emulator_run”。可用车道:测试

任何提示使用任何插件并为此传递设置参数?

【问题讨论】:

    标签: android android-emulator fastlane fastlane-deliver


    【解决方案1】:

    我还没有完全做到这一点,但做了类似的事情,所以我相信以下应该可以工作:

    lane :your_emulator_lane do |options|
        avdSetupPath = options[:AVD_setup_path]
    
        automated_test_emulator_run(
            AVD_setup_path: avdSetupPath,
        )
    
    end
    

    然后会打电话

    fastlane your_emulator_lane AVD_setup_path:avd.json
    

    【讨论】:

    • 感谢您的帮助。我也在做同样的事情。我不想使用文件进行车道设置
    • 设置 Jenkins 流水线作业,Jenkins 流水线不支持安卓模拟器。存储库可能没有 Fastlane 文件,用户可以在运行时输入自定义模拟器配置
    • 找到解决方案:fastlane runautomated_test_emulator_run AVD_setup_path:"avd.json"
    猜你喜欢
    • 2011-07-06
    • 2016-11-08
    • 1970-01-01
    • 2016-09-24
    • 2016-02-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-11-20
    相关资源
    最近更新 更多