xebia-functional / nine-cards-v2

An Open Source Android Launcher built with Scala on Android
http://www.9cards.io/
Other
182 stars 20 forks source link

Improving how the apps are ranked #934

Closed franciscodr closed 7 years ago

franciscodr commented 7 years ago

We need to change how the apps are ranked based on Google Analytics info. We should:

franciscodr commented 7 years ago

The PR's link is https://github.com/47deg/nine-cards-backend/pull/127 The feature branch is paco-934-improving-apps-ranking

QA instructions
  1. Run the app by typing sbt -Dconfig.file=modules/api/src/main/resources/localhost.conf
  2. Make a call to the rankApps endpoint
  3. Check if for all the apps included into the response, they only appear within their category or within one or more moments
curl -X "POST" "https://nine-cards.herokuapp.com/applications/rank" \
     -H "X-Auth-Token: 12345" \
     -H "X-Android-ID: <enter-android-id>" \
     -H "Content-Type: application/json" \
     -H "X-Session-Token: <enter-session-token>" \
     -d $'{
    "location": "ES",
    "items": {
        "BOOKS_AND_REFERENCE": ["com.google.android.apps.books"],
        "BUSINESS": ["com.google.android.apps.giant"],
        "COMMUNICATION": ["com.google.android.talk", "com.google.android.gm", "com.motorola.targetnotif", "com.whatsapp", "com.Slack"],
        "ENTERTAINMENT": ["com.google.android.play.games", "com.netflix.mediaclient", "com.google.android.apps.youtube.kids"],
        "FINANCE": ["com.cajasur.android", "www.ingdirect.nativeframe"],
        "GAME_EDUCATIONAL": ["com.budgestudios.CaillouGoodNight"],
        "GAME_PUZZLE": ["com.budgestudios.caillouhouseofpuzzles","com.developandroid.android.animals","com.developandroid.android.fruit"],
        "GAME_SPORTS": ["com.junerking.archery"],
        "MEDIA_AND_VIDEO": ["com.google.android.youtube", "com.google.android.videos"],
        "MISC": ["com.android.email", "com.android.dialer", "com.android.mms", "com.android.settings", "com.android.vending", "com.motorola.MotGallery2", "com.android.providers.downloads.ui", "com.delaware.empark"],
        "MUSIC_AND_AUDIO": ["com.google.android.music", "com.spotify.music"],
        "NEWS_AND_MAGAZINES": ["com.google.android.apps.magazines", "com.twitter.android"],
        "PERSONALIZATION": ["com.motorola.moto"],
        "PHOTOGRAPHY": ["com.google.android.apps.photos", "com.motorola.camera", "com.google.android.GoogleCamera", "com.niksoftware.snapseed"],
        "PRODUCTIVITY": ["com.google.android.apps.docs.editors.sheets", "com.google.android.apps.docs.editors.slides", "com.google.android.apps.docs", "com.google.android.calendar", "com.google.android.apps.docs.editors.docs", "com.google.android.apps.inbox", "com.koushikdutta.vysor", "com.touchtype.swiftkey"],
        "SHOPPING": ["com.amazon.mShop.android.shopping"],
        "SOCIAL": ["com.google.android.apps.plus"],
        "TOOLS": ["com.android.contacts", "com.google.android.launcher", "com.google.android.deskclock", "com.android.chrome", "com.asus.filemanager", "com.android.calculator2", "com.google.android.googlequicksearchbox", "com.google.android.googlequicksearchbox", "com.motorola.genie", "com.google.android.apps.translate", "com.quickoffice.android", "com.google.android.apps.maps"],
        "TRAVEL_AND_LOCAL": ["com.google.android.apps.maps"]
    }
}'
fedefernandez commented 7 years ago

It works fine, the only issue is that in the response is always including the GAME array even when it's empty

fedefernandez commented 7 years ago

Besides that, LGTM

franciscodr commented 7 years ago

Good catch! I just fixed it. Thanks!