Skip to content

Create logic to be able to run MQA in preproduction (OA), production (Market), and development mode (off) #13

@ghost

Description

We need logic like we have in iOS that allows for different variables be set for the state of MQA when it's built through Jenkins.

Here's some example code from iOS:

var isDevelopment = true
        // Read configurations from the Config.plist.
        let configurationPath = NSBundle.mainBundle().pathForResource("Config", ofType: "plist")
        if((configurationPath) != nil){
            let configuration = NSDictionary(contentsOfFile: configurationPath!) as! [String: AnyObject]!

            if let isDev = configuration["isDevelopment"] as? Bool {
                isDevelopment = isDev
            }
        }

        //Set the SDK mode Market vs QA for Production and Pre-Production
        #if Debug
            // Do nothing
        #else
            if isDevelopment {
                MQALogger.settings().mode = MQAMode.QA
            } else {
                MQALogger.settings().mode = MQAMode.Market
            }
        #endif

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions