common:
  tags:
    - drivers
    - flash
tests:
  drivers.flash.common.nrf_qspi_nor:
    platform_allow: nrf52840dk/nrf52840
    extra_args: EXTRA_CONF_FILE=boards/nrf52840dk_nrf52840_qspi_nor.conf
    integration_platforms:
      - nrf52840dk/nrf52840
  drivers.flash.common.nrf_qspi_nor.size_in_bytes:
    platform_allow: nrf52840dk/nrf52840
    extra_args:
      - EXTRA_CONF_FILE=boards/nrf52840dk_nrf52840_qspi_nor.conf
      - DTC_OVERLAY_FILE=boards/nrf52840_size_in_bytes.overlay
    extra_configs:
      - CONFIG_TEST_DRIVER_FLASH_SIZE=8388608
    integration_platforms:
      - nrf52840dk/nrf52840
  drivers.flash.common.nrf_qspi_nor_4B_addr:
    platform_allow: nrf52840dk/nrf52840
    extra_configs:
      - CONFIG_TEST_DRIVER_FLASH_SIZE=67108864
    extra_args:
      - EXTRA_CONF_FILE=boards/nrf52840dk_nrf52840_qspi_nor.conf
      - DTC_OVERLAY_FILE=boards/nrf52840dk_mx25l51245g.overlay
    harness_config:
      fixture: external_flash_mx25l51245g
    integration_platforms:
      - nrf52840dk/nrf52840
  drivers.flash.common.soc_flash_nrf:
    platform_allow: nrf52840dk/nrf52840
    extra_args: EXTRA_CONF_FILE=boards/nrf52840dk_nrf52840_soc.conf
    integration_platforms:
      - nrf52840dk/nrf52840
  drivers.flash.common.default:
    filter: ((CONFIG_FLASH_HAS_DRIVER_ENABLED and not CONFIG_TRUSTED_EXECUTION_NONSECURE)
      and (dt_label_with_parent_compat_enabled("storage_partition", "fixed-partitions")
      or dt_label_with_parent_compat_enabled("storage_partition", "nordic,owned-partitions")))
    integration_platforms:
      - qemu_x86
      - mimxrt1060_evk/mimxrt1062/qspi
  drivers.flash.common.no_explicit_erase:
    platform_allow:
      - nrf54l15dk/nrf54l05/cpuapp
      - nrf54l15dk/nrf54l10/cpuapp
      - nrf54l15dk/nrf54l15/cpuapp
      - nrf54h20dk/nrf54h20/cpuapp
  drivers.flash.common.tfm_ns:
    build_only: true
    filter: (CONFIG_FLASH_HAS_DRIVER_ENABLED and CONFIG_TRUSTED_EXECUTION_NONSECURE
      and dt_label_with_parent_compat_enabled("storage_partition", "fixed-partitions"))
    integration_platforms:
      - nrf9161dk/nrf9161/ns
  drivers.flash.common.mx25r_high_perf:
    platform_allow: nrf52840dk/nrf52840
    extra_configs:
      - CONFIG_TEST_DRIVER_FLASH_SIZE=8388608
    extra_args:
      - EXTRA_CONF_FILE=boards/nrf52840dk_flash_spi.conf
      - DTC_OVERLAY_FILE=boards/nrf52840dk_mx25r_high_perf.overlay
    integration_platforms:
      - nrf52840dk/nrf52840
  drivers.flash.common.mr_canhubk3_sfdp_runtime:
    platform_allow: mr_canhubk3
    extra_configs:
      - CONFIG_FLASH_NXP_S32_QSPI_NOR_SFDP_RUNTIME=y
  drivers.flash.common.spi_nor:
    platform_allow: nrf52840dk/nrf52840
    extra_configs:
      - CONFIG_TEST_DRIVER_FLASH_SIZE=2097152
    extra_args:
      - EXTRA_CONF_FILE=boards/nrf52840dk_flash_spi.conf
      - DTC_OVERLAY_FILE=boards/nrf52840dk_spi_nor.overlay
    harness_config:
      fixture: external_flash_mx25v1635f
  drivers.flash.common.spi_nor_wp_hold:
    platform_allow: nrf52840dk/nrf52840
    extra_configs:
      - CONFIG_TEST_DRIVER_FLASH_SIZE=2097152
    extra_args:
      - EXTRA_CONF_FILE=boards/nrf52840dk_flash_spi.conf
      - DTC_OVERLAY_FILE=boards/nrf52840dk_spi_nor_wp_hold.overlay
    harness_config:
      fixture: external_flash_mx25v1635f
  drivers.flash.common.sam0:
    platform_allow:
      - samd20_xpro
      - samr21_xpro
      - same54_xpro
  drivers.flash.common.gd32:
    platform_allow:
      - gd32vf103v_eval
      - gd32a503v_eval
      - gd32f470i_eval
