0

I am getting the following error in my index.js:

Uncaught ReferenceError: MQA is not defined

I have the following code in my index.js file:

MQA.startNewSession({
    //Required for IBM MobileFirst Quality Assurance
    // or "MARKET" if it is production mode.

    mode: "QA",
    shake: true,
    protocol: 'http',
    host: 'ourhostnamehere:80',
    versionName: "1.0", // app release version
    android: {
      appKey: "91719217347da8e6daf648192dc774664978bba1",
      versionNumber: "1" // app version number
    }
     /*ios: {
         applicationKey: "<iOS MQA application key>",
         versionNumber: "1.0" // app version number
     }*/
},{
      success: function () { console.log("mqa success"); },
      error: function (e) { console.log("mqa failed: " + e); }
});

I have confirmed that both mqa.js and tracekit.js are loading in my app via chrome inspect.
What am I missing?

Idan Adar
  • 44,156
  • 13
  • 50
  • 89
KayVan
  • 3
  • 1
  • @Idan Adar - I was able to fix this error by putting it inside of wlCommonInit(). However now it is saying failed: Class not Found. What does this mean? – KayVan Oct 18 '16 at 17:49
  • @Idan Adar However now it is saying failed: Class not Found. What does this mean? – KayVan Oct 18 '16 at 17:50
  • I don't know. You haven't really provided anything that can be worked with... if you have a project you can upload, it could be debugged. – Idan Adar Oct 18 '16 at 17:51
  • Unfortunately I cannot share the project. What other information would be helpful? I am just trying to add this to a MFP8.0 Cordova Project using the Javascript SDKs. – KayVan Oct 18 '16 at 17:53
  • Android or iOS? – Idan Adar Oct 18 '16 at 17:55
  • Right now I am focusing on Android. – KayVan Oct 18 '16 at 18:01

1 Answers1

0

MobileFirst Foundation 8.0 supports Cordova applications that are created at minimum with cordova-ios@4.0.1 and cordova-android@5.1.1.

MobileFirst Quality Assurance currently does not support the required plug-in version minimum mentioned above, as such you cannot use MobileFirst Foundation 8.0 with MobileFirst Quality Assurance until the MQA team updates their Cordova plug-in to the required minimum.

Idan Adar
  • 44,156
  • 13
  • 50
  • 89
  • I see that for the SDK for Apache Cordova. Can I use the Javascript SDK? It supports iOS 6.1 or later and Android 4.0 or later. – KayVan Oct 18 '16 at 18:06
  • The JavaScript SDK is meant for Hybrid applications created in MobileFirst Studio 7.1. In MobileFirst Foundation 8.0 there is no more support for Hybrid apps like those in 7.1, rather only standard Cordova applications. What you need to do is contact the Quality Assurance team and have them update their Cordova plug-in to meet the requirements of newer Cordova releases, that's the problem here. – Idan Adar Oct 18 '16 at 18:10
  • iOS 6.1 refers to the iOS OS version, not the Cordova plug-in version. QA is simply not supported in MobileFirst Foundation 8.0 at this time. – Idan Adar Oct 18 '16 at 18:10