# Global Metrics

path: .metrics.halstead.n2
old: 112.0
new: 95.0
path: .metrics.halstead.length
old: 624.0
new: 530.0
path: .metrics.halstead.bugs
old: 0.7130871535459775
new: 0.6558587346880103
path: .metrics.halstead.N2
old: 298.0
new: 241.0
path: .metrics.halstead.estimated_program_length
old: 831.9106195717073
new: 704.8469055468681
path: .metrics.halstead.time
old: 5496.969102234102
new: 4848.694675051458
path: .metrics.halstead.vocabulary
old: 129.0
new: 114.0
path: .metrics.halstead.purity_ratio
old: 1.3331900954674798
new: 1.3298998217865436
path: .metrics.halstead.N1
old: 326.0
new: 289.0
path: .metrics.halstead.volume
old: 4375.00580738411
new: 3621.4317075073127
path: .metrics.halstead.difficulty
old: 22.616071428571427
new: 24.1
path: .metrics.halstead.level
old: 0.04421634425582314
new: 0.04149377593360996
path: .metrics.halstead.n1
old: 17.0
new: 19.0
path: .metrics.halstead.effort
old: 98945.44384021383
new: 87276.50415092624
path: .metrics.loc.sloc
old: 207.0
new: 146.0
path: .metrics.loc.ploc
old: 134.0
new: 110.0
path: .metrics.loc.cloc
old: 40.0
new: 10.0
path: .metrics.loc.blank
old: 33.0
new: 26.0
path: .metrics.loc.lloc
old: 9.0
new: 47.0
path: .metrics.nargs.average
old: 0.0
new: 4.4
path: .metrics.nargs.sum
old: 0.0
new: 22.0
path: .metrics.cyclomatic.sum
old: 17.0
new: 18.0
path: .metrics.cyclomatic.average
old: 1.0625
new: 2.25
path: .metrics.mi.mi_sei
old: 11.039868433330934
new: 8.629918862384166
path: .metrics.mi.mi_original
old: 37.10490729289786
new: 43.5135241534266
path: .metrics.mi.mi_visual_studio
old: 21.698776194677112
new: 25.446505352881054
path: .metrics.nom.functions
old: 10.0
new: 5.0
path: .metrics.nom.total
old: 10.0
new: 5.0
path: .metrics.cognitive.average
old: 0.1
new: 2.2
path: .metrics.cognitive.sum
old: 1.0
new: 11.0
path: .metrics.nexits.average
old: 0.8
new: 1.4
path: .metrics.nexits.sum
old: 8.0
new: 7.0

# Spaces Data

## Minimal test - lines (12, 146)

path: .spaces[0].metrics.mi.mi_visual_studio
old: 22.76946776448793
new: 26.38085775969449
path: .spaces[0].metrics.mi.mi_original
old: 38.93578987727436
new: 45.111266769077574
path: .spaces[0].metrics.mi.mi_sei
old: 12.254026071275725
new: 5.799139567816432
path: .spaces[0].metrics.cognitive.average
old: 0.1
new: 2.2
path: .spaces[0].metrics.cognitive.sum
old: 1.0
new: 11.0
path: .spaces[0].metrics.loc.sloc
old: 189.0
new: 135.0
path: .spaces[0].metrics.loc.blank
old: 31.0
new: 25.0
path: .spaces[0].metrics.loc.cloc
old: 33.0
new: 5.0
path: .spaces[0].metrics.loc.lloc
old: 9.0
new: 47.0
path: .spaces[0].metrics.loc.ploc
old: 125.0
new: 105.0
path: .spaces[0].metrics.nom.functions
old: 10.0
new: 5.0
path: .spaces[0].metrics.nom.total
old: 10.0
new: 5.0
path: .spaces[0].metrics.nexits.average
old: 0.8
new: 1.4
path: .spaces[0].metrics.nexits.sum
old: 8.0
new: 7.0
path: .spaces[0].metrics.cyclomatic.sum
old: 16.0
new: 17.0
path: .spaces[0].metrics.cyclomatic.average
old: 1.0666666666666669
new: 2.4285714285714284
path: .spaces[0].metrics.halstead.purity_ratio
old: 1.257277025415907
new: 1.266623621762093
path: .spaces[0].metrics.halstead.time
old: 5568.205715793116
new: 4917.587258937458
path: .spaces[0].metrics.halstead.volume
old: 4269.3341999387385
new: 3553.2967705078863
path: .spaces[0].metrics.halstead.n2
old: 105.0
new: 90.0
path: .spaces[0].metrics.halstead.N1
old: 326.0
new: 289.0
path: .spaces[0].metrics.halstead.N2
old: 290.0
new: 236.0
path: .spaces[0].metrics.halstead.estimated_program_length
old: 774.4826476561987
new: 664.9774014250988
path: .spaces[0].metrics.halstead.n1
old: 17.0
new: 19.0
path: .spaces[0].metrics.halstead.level
old: 0.042596348884381345
new: 0.04014272970561998
path: .spaces[0].metrics.halstead.length
old: 616.0
new: 525.0
path: .spaces[0].metrics.halstead.difficulty
old: 23.47619047619047
new: 24.91111111111111
path: .spaces[0].metrics.halstead.effort
old: 100227.70288427608
new: 88516.57066087423
path: .spaces[0].metrics.halstead.bugs
old: 0.7192346411373284
new: 0.662056619162238
path: .spaces[0].metrics.halstead.vocabulary
old: 122.0
new: 109.0
path: .spaces[0].metrics.nargs.average
old: 0.0
new: 4.4
path: .spaces[0].metrics.nargs.sum
old: 0.0
new: 22.0

### Code

    namespace mozilla {
    namespace widget {

    NS_IMPL_ISUPPORTS(AndroidAlerts, nsIAlertsService)

    StaticAutoPtr AndroidAlerts::sListenerMap;
    nsTHashMap
        AndroidAlerts::mNotificationsMap;

    NS_IMETHODIMP
    AndroidAlerts::ShowAlertNotification(
        const nsAString& aImageUrl, const nsAString& aAlertTitle,
        const nsAString& aAlertText, bool aAlertTextClickable,
        const nsAString& aAlertCookie, nsIObserver* aAlertListener,
        const nsAString& aAlertName, const nsAString& aBidi, const nsAString& aLang,
        const nsAString& aData, nsIPrincipal* aPrincipal, bool aInPrivateBrowsing,
        bool aRequireInteraction) {
      MOZ_ASSERT_UNREACHABLE("Should be implemented by nsAlertsService.");
      return NS_ERROR_NOT_IMPLEMENTED;
    }

    NS_IMETHODIMP
    AndroidAlerts::ShowAlert(nsIAlertNotification* aAlert,
                             nsIObserver* aAlertListener) {
      return ShowPersistentNotification(u""_ns, aAlert, aAlertListener);
    }

    NS_IMETHODIMP
    AndroidAlerts::ShowPersistentNotification(const nsAString& aPersistentData,
                                              nsIAlertNotification* aAlert,
                                              nsIObserver* aAlertListener) {
      // nsAlertsService disables our alerts backend if we ever return failure
      // here. To keep the backend enabled, we always return NS_OK even if we
      // encounter an error here.
      nsresult rv;

      nsAutoString imageUrl;
      rv = aAlert->GetImageURL(imageUrl);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString title;
      rv = aAlert->GetTitle(title);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString text;
      rv = aAlert->GetText(text);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString cookie;
      rv = aAlert->GetCookie(cookie);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString name;
      rv = aAlert->GetName(name);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString lang;
      rv = aAlert->GetLang(lang);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString dir;
      rv = aAlert->GetDir(dir);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      bool requireInteraction;
      rv = aAlert->GetRequireInteraction(&requireInteraction);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCOMPtr uri;
      rv = aAlert->GetURI(getter_AddRefs(uri));
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCString spec;
      if (uri) {
        rv = uri->GetDisplaySpec(spec);
        NS_ENSURE_SUCCESS(rv, NS_OK);
      }

      if (aPersistentData.IsEmpty() && aAlertListener) {
        if (!sListenerMap) {
          sListenerMap = new ListenerMap();
        }
        // This will remove any observers already registered for this name.
        sListenerMap->InsertOrUpdate(name, aAlertListener);
      }

      java::WebNotification::LocalRef notification = notification->New(
          title, name, cookie, text, imageUrl, dir, lang, requireInteraction, spec);
      java::GeckoRuntime::LocalRef runtime = java::GeckoRuntime::GetInstance();
      if (runtime != NULL) {
        runtime->NotifyOnShow(notification);
      }
      mNotificationsMap.InsertOrUpdate(name, notification);

      return NS_OK;
    }

    NS_IMETHODIMP
    AndroidAlerts::CloseAlert(const nsAString& aAlertName) {
      java::WebNotification::LocalRef notification =
          mNotificationsMap.Get(aAlertName);
      if (!notification) {
        return NS_OK;
      }

      java::GeckoRuntime::LocalRef runtime = java::GeckoRuntime::GetInstance();
      if (runtime != NULL) {
        runtime->NotifyOnClose(notification);
      }
      mNotificationsMap.Remove(aAlertName);

      return NS_OK;
    }

    void AndroidAlerts::NotifyListener(const nsAString& aName, const char* aTopic,
                                       const char16_t* aCookie) {
      if (!sListenerMap) {
        return;
      }

      nsCOMPtr listener = sListenerMap->Get(aName);
      if (!listener) {
        return;
      }

      listener->Observe(nullptr, aTopic, aCookie);

      if ("alertfinished"_ns.Equals(aTopic)) {
        sListenerMap->Remove(aName);
        mNotificationsMap.Remove(aName);
      }
    }

    }  // namespace widget
    }  // namespace mozilla

## Minimal test - lines (13, 145)

path: .spaces[0].spaces[0].metrics.cyclomatic.average
old: 1.0714285714285714
new: 2.6666666666666665
path: .spaces[0].spaces[0].metrics.cyclomatic.sum
old: 15.0
new: 16.0
path: .spaces[0].spaces[0].metrics.nargs.average
old: 0.0
new: 4.4
path: .spaces[0].spaces[0].metrics.nargs.sum
old: 0.0
new: 22.0
path: .spaces[0].spaces[0].metrics.halstead.vocabulary
old: 121.0
new: 108.0
path: .spaces[0].spaces[0].metrics.halstead.effort
old: 100342.87645203977
new: 88617.86247536303
path: .spaces[0].spaces[0].metrics.halstead.estimated_program_length
old: 766.3325989879293
new: 657.0508981114376
path: .spaces[0].spaces[0].metrics.halstead.n2
old: 104.0
new: 89.0
path: .spaces[0].spaces[0].metrics.halstead.level
old: 0.04233665784652962
new: 0.03986562150055991
path: .spaces[0].spaces[0].metrics.halstead.purity_ratio
old: 1.24809869542008
new: 1.2563114686643166
path: .spaces[0].spaces[0].metrics.halstead.N2
old: 289.0
new: 235.0
path: .spaces[0].spaces[0].metrics.halstead.N1
old: 325.0
new: 288.0
path: .spaces[0].spaces[0].metrics.halstead.time
old: 5574.604247335542
new: 4923.214581964613
path: .spaces[0].spaces[0].metrics.halstead.n1
old: 17.0
new: 19.0
path: .spaces[0].spaces[0].metrics.halstead.difficulty
old: 23.620192307692307
new: 25.084269662921347
path: .spaces[0].spaces[0].metrics.halstead.bugs
old: 0.719785526507989
new: 0.6625615952913702
path: .spaces[0].spaces[0].metrics.halstead.volume
old: 4248.182027686601
new: 3532.8061636314937
path: .spaces[0].spaces[0].metrics.halstead.length
old: 614.0
new: 523.0
path: .spaces[0].spaces[0].metrics.nom.functions
old: 10.0
new: 5.0
path: .spaces[0].spaces[0].metrics.nom.total
old: 10.0
new: 5.0
path: .spaces[0].spaces[0].metrics.loc.sloc
old: 187.0
new: 133.0
path: .spaces[0].spaces[0].metrics.loc.lloc
old: 9.0
new: 47.0
path: .spaces[0].spaces[0].metrics.loc.ploc
old: 123.0
new: 103.0
path: .spaces[0].spaces[0].metrics.loc.blank
old: 32.0
new: 26.0
path: .spaces[0].spaces[0].metrics.loc.cloc
old: 32.0
new: 4.0
path: .spaces[0].spaces[0].metrics.mi.mi_sei
old: 12.510686928652715
new: 5.006299960483377
path: .spaces[0].spaces[0].metrics.mi.mi_visual_studio
old: 23.01985910143333
new: 26.674348339122275
path: .spaces[0].spaces[0].metrics.mi.mi_original
old: 39.36395906345099
new: 45.613135659899086
path: .spaces[0].spaces[0].metrics.cognitive.average
old: 0.1
new: 2.2
path: .spaces[0].spaces[0].metrics.cognitive.sum
old: 1.0
new: 11.0
path: .spaces[0].spaces[0].metrics.nexits.average
old: 0.8
new: 1.4
path: .spaces[0].spaces[0].metrics.nexits.sum
old: 8.0
new: 7.0

### Code

    namespace widget {

    NS_IMPL_ISUPPORTS(AndroidAlerts, nsIAlertsService)

    StaticAutoPtr AndroidAlerts::sListenerMap;
    nsTHashMap
        AndroidAlerts::mNotificationsMap;

    NS_IMETHODIMP
    AndroidAlerts::ShowAlertNotification(
        const nsAString& aImageUrl, const nsAString& aAlertTitle,
        const nsAString& aAlertText, bool aAlertTextClickable,
        const nsAString& aAlertCookie, nsIObserver* aAlertListener,
        const nsAString& aAlertName, const nsAString& aBidi, const nsAString& aLang,
        const nsAString& aData, nsIPrincipal* aPrincipal, bool aInPrivateBrowsing,
        bool aRequireInteraction) {
      MOZ_ASSERT_UNREACHABLE("Should be implemented by nsAlertsService.");
      return NS_ERROR_NOT_IMPLEMENTED;
    }

    NS_IMETHODIMP
    AndroidAlerts::ShowAlert(nsIAlertNotification* aAlert,
                             nsIObserver* aAlertListener) {
      return ShowPersistentNotification(u""_ns, aAlert, aAlertListener);
    }

    NS_IMETHODIMP
    AndroidAlerts::ShowPersistentNotification(const nsAString& aPersistentData,
                                              nsIAlertNotification* aAlert,
                                              nsIObserver* aAlertListener) {
      // nsAlertsService disables our alerts backend if we ever return failure
      // here. To keep the backend enabled, we always return NS_OK even if we
      // encounter an error here.
      nsresult rv;

      nsAutoString imageUrl;
      rv = aAlert->GetImageURL(imageUrl);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString title;
      rv = aAlert->GetTitle(title);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString text;
      rv = aAlert->GetText(text);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString cookie;
      rv = aAlert->GetCookie(cookie);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString name;
      rv = aAlert->GetName(name);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString lang;
      rv = aAlert->GetLang(lang);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString dir;
      rv = aAlert->GetDir(dir);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      bool requireInteraction;
      rv = aAlert->GetRequireInteraction(&requireInteraction);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCOMPtr uri;
      rv = aAlert->GetURI(getter_AddRefs(uri));
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCString spec;
      if (uri) {
        rv = uri->GetDisplaySpec(spec);
        NS_ENSURE_SUCCESS(rv, NS_OK);
      }

      if (aPersistentData.IsEmpty() && aAlertListener) {
        if (!sListenerMap) {
          sListenerMap = new ListenerMap();
        }
        // This will remove any observers already registered for this name.
        sListenerMap->InsertOrUpdate(name, aAlertListener);
      }

      java::WebNotification::LocalRef notification = notification->New(
          title, name, cookie, text, imageUrl, dir, lang, requireInteraction, spec);
      java::GeckoRuntime::LocalRef runtime = java::GeckoRuntime::GetInstance();
      if (runtime != NULL) {
        runtime->NotifyOnShow(notification);
      }
      mNotificationsMap.InsertOrUpdate(name, notification);

      return NS_OK;
    }

    NS_IMETHODIMP
    AndroidAlerts::CloseAlert(const nsAString& aAlertName) {
      java::WebNotification::LocalRef notification =
          mNotificationsMap.Get(aAlertName);
      if (!notification) {
        return NS_OK;
      }

      java::GeckoRuntime::LocalRef runtime = java::GeckoRuntime::GetInstance();
      if (runtime != NULL) {
        runtime->NotifyOnClose(notification);
      }
      mNotificationsMap.Remove(aAlertName);

      return NS_OK;
    }

    void AndroidAlerts::NotifyListener(const nsAString& aName, const char* aTopic,
                                       const char16_t* aCookie) {
      if (!sListenerMap) {
        return;
      }

      nsCOMPtr listener = sListenerMap->Get(aName);
      if (!listener) {
        return;
      }

      listener->Observe(nullptr, aTopic, aCookie);

      if ("alertfinished"_ns.Equals(aTopic)) {
        sListenerMap->Remove(aName);
        mNotificationsMap.Remove(aName);
      }
    }

    }  // namespace widget

## Minimal test - lines (40, 107)

path: .spaces[0].spaces[0].spaces[2].metrics.nexits.sum
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[2].metrics.nexits.average
old: null
new: 1.0
path: .spaces[0].spaces[0].spaces[2].metrics.cognitive.average
old: null
new: 6.0
path: .spaces[0].spaces[0].spaces[2].metrics.cognitive.sum
old: 0.0
new: 6.0
path: .spaces[0].spaces[0].spaces[2].metrics.nom.total
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[2].metrics.nom.functions
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[2].metrics.mi.mi_sei
old: 52.613419515858
new: 33.39558200304107
path: .spaces[0].spaces[0].spaces[2].metrics.mi.mi_visual_studio
old: 51.97081834667412
new: 36.53725402040642
path: .spaces[0].spaces[0].spaces[2].metrics.mi.mi_original
old: 88.87009937281275
new: 62.478704374894974
path: .spaces[0].spaces[0].spaces[2].metrics.nargs.average
old: null
new: 3.0
path: .spaces[0].spaces[0].spaces[2].metrics.nargs.sum
old: 0.0
new: 3.0
path: .spaces[0].spaces[0].spaces[2].metrics.loc.cloc
old: 0.0
new: 4.0
path: .spaces[0].spaces[0].spaces[2].metrics.loc.blank
old: 3.0
new: 13.0
path: .spaces[0].spaces[0].spaces[2].metrics.loc.lloc
old: 0.0
new: 29.0
path: .spaces[0].spaces[0].spaces[2].metrics.loc.ploc
old: 20.0
new: 51.0
path: .spaces[0].spaces[0].spaces[2].metrics.loc.sloc
old: 23.0
new: 68.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.n1
old: 10.0
new: 19.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.bugs
old: 0.05571006715967356
new: 0.4343740963166748
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.time
old: 120.03555366462216
new: 2613.39619592003
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.difficulty
old: 5.454545454545454
new: 27.114583333333332
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.length
old: 73.0
new: 286.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.volume
old: 396.1173270932531
new: 1734.9015084709229
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.N1
old: 37.0
new: 149.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.purity_ratio
old: 2.7354011902425013
new: 1.219541338426726
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.N2
old: 36.0
new: 137.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.effort
old: 2160.639965963199
new: 47041.131526560544
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.level
old: 0.18333333333333335
new: 0.03688052247406839
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.n2
old: 33.0
new: 48.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.vocabulary
old: 43.0
new: 67.0
path: .spaces[0].spaces[0].spaces[2].metrics.halstead.estimated_program_length
old: 199.6842868877026
new: 348.78882279004364
path: .spaces[0].spaces[0].spaces[2].metrics.cyclomatic.sum
old: 1.0
new: 6.0
path: .spaces[0].spaces[0].spaces[2].metrics.cyclomatic.average
old: 1.0
new: 6.0

### Code

    AndroidAlerts::ShowPersistentNotification(const nsAString& aPersistentData,
                                              nsIAlertNotification* aAlert,
                                              nsIObserver* aAlertListener) {
      // nsAlertsService disables our alerts backend if we ever return failure
      // here. To keep the backend enabled, we always return NS_OK even if we
      // encounter an error here.
      nsresult rv;

      nsAutoString imageUrl;
      rv = aAlert->GetImageURL(imageUrl);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString title;
      rv = aAlert->GetTitle(title);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString text;
      rv = aAlert->GetText(text);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString cookie;
      rv = aAlert->GetCookie(cookie);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString name;
      rv = aAlert->GetName(name);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString lang;
      rv = aAlert->GetLang(lang);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsAutoString dir;
      rv = aAlert->GetDir(dir);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      bool requireInteraction;
      rv = aAlert->GetRequireInteraction(&requireInteraction);
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCOMPtr uri;
      rv = aAlert->GetURI(getter_AddRefs(uri));
      NS_ENSURE_SUCCESS(rv, NS_OK);

      nsCString spec;
      if (uri) {
        rv = uri->GetDisplaySpec(spec);
        NS_ENSURE_SUCCESS(rv, NS_OK);
      }

      if (aPersistentData.IsEmpty() && aAlertListener) {
        if (!sListenerMap) {
          sListenerMap = new ListenerMap();
        }
        // This will remove any observers already registered for this name.
        sListenerMap->InsertOrUpdate(name, aAlertListener);
      }

      java::WebNotification::LocalRef notification = notification->New(
          title, name, cookie, text, imageUrl, dir, lang, requireInteraction, spec);
      java::GeckoRuntime::LocalRef runtime = java::GeckoRuntime::GetInstance();
      if (runtime != NULL) {
        runtime->NotifyOnShow(notification);
      }
      mNotificationsMap.InsertOrUpdate(name, notification);

      return NS_OK;
    }

## Minimal test - lines (34, 37)

path: .spaces[0].spaces[0].spaces[1].metrics.loc.ploc
old: 96.0
new: 4.0
path: .spaces[0].spaces[0].spaces[1].metrics.loc.cloc
old: 2.0
new: 0.0
path: .spaces[0].spaces[0].spaces[1].metrics.loc.sloc
old: 117.0
new: 4.0
path: .spaces[0].spaces[0].spaces[1].metrics.loc.blank
old: 19.0
new: 0.0
path: .spaces[0].spaces[0].spaces[1].metrics.loc.lloc
old: 9.0
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.cognitive.average
old: 0.1
new: 0.0
path: .spaces[0].spaces[0].spaces[1].metrics.cognitive.sum
old: 1.0
new: 0.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.n2
old: 83.0
new: 8.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.purity_ratio
old: 1.1380515990552291
new: 2.0786421168763445
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.time
old: 4871.249565594568
new: 19.94142074841848
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.N1
old: 281.0
new: 11.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.bugs
old: 0.6578910860555601
new: 0.01683569876963146
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.volume
old: 3494.668355821505
new: 82.0447025077789
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.level
old: 0.03985594237695078
new: 0.22857142857142856
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.N2
old: 245.0
new: 10.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.length
old: 526.0
new: 21.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.vocabulary
old: 100.0
new: 15.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.effort
old: 87682.49218070222
new: 358.94557347153267
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.estimated_program_length
old: 598.6151411030505
new: 43.65148445440323
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.n1
old: 17.0
new: 7.0
path: .spaces[0].spaces[0].spaces[1].metrics.halstead.difficulty
old: 25.09036144578313
new: 4.375
path: .spaces[0].spaces[0].spaces[1].metrics.nexits.average
old: 0.8
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.nexits.sum
old: 8.0
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.mi.mi_original
old: 48.6660147088145
new: 125.39425724332408
path: .spaces[0].spaces[0].spaces[1].metrics.mi.mi_sei
old: 5.78949284243922
new: 105.30664094829032
path: .spaces[0].spaces[0].spaces[1].metrics.mi.mi_visual_studio
old: 28.459657724452924
new: 73.32997499609597
path: .spaces[0].spaces[0].spaces[1].metrics.cyclomatic.sum
old: 12.0
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.cyclomatic.average
old: 1.0909090909090908
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.nom.functions
old: 10.0
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.nom.total
old: 10.0
new: 1.0
path: .spaces[0].spaces[0].spaces[1].metrics.nargs.average
old: 0.0
new: 2.0
path: .spaces[0].spaces[0].spaces[1].metrics.nargs.sum
old: 0.0
new: 2.0

### Code

    AndroidAlerts::ShowAlert(nsIAlertNotification* aAlert,
                             nsIObserver* aAlertListener) {
      return ShowPersistentNotification(u""_ns, aAlert, aAlertListener);
    }

## Minimal test - lines (22, 31)

path: .spaces[0].spaces[0].spaces[0].metrics.nom.functions
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[0].metrics.nom.total
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.level
old: null
new: 0.1646090534979424
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.n1
old: 0.0
new: 9.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.N1
old: 0.0
new: 32.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.purity_ratio
old: null
new: 1.9486082527242043
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.volume
old: 0.0
new: 286.62087871252675
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.bugs
old: 0.0
new: 0.04824453766769427
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.n2
old: 1.0
new: 20.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.effort
old: 0.0
new: 1741.2218381786
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.estimated_program_length
old: null
new: 114.96788691072804
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.vocabulary
old: 1.0
new: 29.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.N2
old: 1.0
new: 27.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.length
old: 1.0
new: 59.0
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.difficulty
old: 0.0
new: 6.075
path: .spaces[0].spaces[0].spaces[0].metrics.halstead.time
old: 0.0
new: 96.7345465654778
path: .spaces[0].spaces[0].spaces[0].metrics.nexits.average
old: null
new: 1.0
path: .spaces[0].spaces[0].spaces[0].metrics.nexits.sum
old: 0.0
new: 1.0
path: .spaces[0].spaces[0].spaces[0].metrics.mi.mi_sei
old: null
new: 74.50716540679782
path: .spaces[0].spaces[0].spaces[0].metrics.mi.mi_visual_studio
old: null
new: 60.84543135030032
path: .spaces[0].spaces[0].spaces[0].metrics.mi.mi_original
old: null
new: 104.04568760901354
path: .spaces[0].spaces[0].spaces[0].metrics.loc.lloc
old: 0.0
new: 2.0
path: .spaces[0].spaces[0].spaces[0].metrics.loc.ploc
old: 1.0
new: 10.0
path: .spaces[0].spaces[0].spaces[0].metrics.loc.sloc
old: 1.0
new: 10.0
path: .spaces[0].spaces[0].spaces[0].metrics.nargs.average
old: null
new: 13.0
path: .spaces[0].spaces[0].spaces[0].metrics.nargs.sum
old: 0.0
new: 13.0
path: .spaces[0].spaces[0].spaces[0].metrics.cognitive.average
old: null
new: 0.0

### Code

    AndroidAlerts::ShowAlertNotification(
        const nsAString& aImageUrl, const nsAString& aAlertTitle,
        const nsAString& aAlertText, bool aAlertTextClickable,
        const nsAString& aAlertCookie, nsIObserver* aAlertListener,
        const nsAString& aAlertName, const nsAString& aBidi, const nsAString& aLang,
        const nsAString& aData, nsIPrincipal* aPrincipal, bool aInPrivateBrowsing,
        bool aRequireInteraction) {
      MOZ_ASSERT_UNREACHABLE("Should be implemented by nsAlertsService.");
      return NS_ERROR_NOT_IMPLEMENTED;
    }