Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Bug Addressables play mode script setting ignored when running Playmode tests in Editor

Discussion in 'Addressables' started by rosen_rusinov, Nov 23, 2021.

  1. rosen_rusinov

    rosen_rusinov

    Joined:
    Apr 6, 2018
    Posts:
    10
    As the title says: When I run my PlayMode tests in the Unity Editor all the addressable operations ignore the current selected play mode script and use "Use Existing Build". I tried forcing the current script selected to the fast mode before running the test but the Editor still does not load the project assets using the AssetDatabase (Use Asset Database) and tries to load remote bundles.

    Is this a bug or some limitation that is not mentioned in the docs?

    Unity: 2020.3.20f1
    Addressables: 1.18.19 (Verified)
    Test Framework: 1.1.30 (Verified)
     
    Last edited: Nov 23, 2021
  2. rosen_rusinov

    rosen_rusinov

    Joined:
    Apr 6, 2018
    Posts:
    10
  3. rosen_rusinov

    rosen_rusinov

    Joined:
    Apr 6, 2018
    Posts:
    10
  4. rosen_rusinov

    rosen_rusinov

    Joined:
    Apr 6, 2018
    Posts:
    10
  5. Onekru

    Onekru

    Joined:
    Sep 14, 2020
    Posts:
    4
    I'm facing the same problem here.
    Same unity version
     
  6. Onekru

    Onekru

    Joined:
    Sep 14, 2020
    Posts:
    4
    So I figured out what's wrong...

    The addressable asset system is saving something to the player pref. That thing is what the editor is using to locate the asset in the asset database.

    I was deleting the player pref keys on start :(