Sha256: 24ad2295b92b4f7b0e30fbff74bef4b2bf0dac55e4887214da32e0bc0dee1a63

Contents?: true

Size: 1.63 KB

Versions: 12

Compression:

Stored size: 1.63 KB

Contents

module Fastlane
  module Actions
    class XctoolAction < Action
      def self.run(params)
        UI.important("Have you seen the new 'scan' tool to run tests? https://github.com/fastlane/fastlane/tree/master/scan")
        unless Helper.test?
          UI.user_error!("xctool not installed, please install using `brew install xctool`") if `which xctool`.length == 0
        end

        params = [] if params.kind_of? FastlaneCore::Configuration

        Actions.sh('xctool ' + params.join(' '))
      end

      def self.description
        "Run tests using xctool"
      end

      def self.details
        [
          "You can run any `xctool` action. This will require having [xctool](https://github.com/facebook/xctool) installed through [homebrew](http://brew.sh/).",
          "It is recommended to store the build configuration in the `.xctool-args` file.",
          "More information available on GitHub: https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Actions.md#xctool"
        ].join(' ')
      end

      def self.author
        "KrauseFx"
      end

      def self.is_supported?(platform)
        [:ios, :mac].include?(platform)
      end

      def self.example_code
        [
          'xctool :test',

          '# If you prefer to have the build configuration stored in the `Fastfile`:
          xctool :test, [
            "--workspace", "\'AwesomeApp.xcworkspace\'",
            "--scheme", "\'Schema Name\'",
            "--configuration", "Debug",
            "--sdk", "iphonesimulator",
            "--arch", "i386"
          ].join(" ")'
        ]
      end

      def self.category
        :testing
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
fastlane-1.111.0 lib/fastlane/actions/xctool.rb
fastlane-1.110.0 lib/fastlane/actions/xctool.rb
fastlane-1.109.0 lib/fastlane/actions/xctool.rb
fastlane-1.108.0 lib/fastlane/actions/xctool.rb
fastlane-1.107.0 lib/fastlane/actions/xctool.rb
fastlane-1.106.2 lib/fastlane/actions/xctool.rb
fastlane-1.106.1 lib/fastlane/actions/xctool.rb
fastlane-1.106.0 lib/fastlane/actions/xctool.rb
fastlane-1.105.3 lib/fastlane/actions/xctool.rb
fastlane-1.105.2 lib/fastlane/actions/xctool.rb
fastlane-1.105.1 lib/fastlane/actions/xctool.rb
fastlane-1.105.0 lib/fastlane/actions/xctool.rb