test: flash: add rt685 support for flash driver test
enable flash test for rt685
Signed-off-by: Hake Huang <hake.huang@oss.nxp.com>
diff --git a/tests/drivers/flash/boards/mimxrt685_evk_cm33.conf b/tests/drivers/flash/boards/mimxrt685_evk_cm33.conf
new file mode 100644
index 0000000..9abcb1b
--- /dev/null
+++ b/tests/drivers/flash/boards/mimxrt685_evk_cm33.conf
@@ -0,0 +1,6 @@
+#
+# Copyright (c) 2022 NXP.
+# SPDX-License-Identifier: Apache-2.0
+#
+
+CONFIG_FLASH_MCUX_FLEXSPI_NOR_WRITE_BUFFER=y
diff --git a/tests/drivers/flash/src/main.c b/tests/drivers/flash/src/main.c
index af30f34..8f98247 100644
--- a/tests/drivers/flash/src/main.c
+++ b/tests/drivers/flash/src/main.c
@@ -20,6 +20,11 @@
#define FLASH_DEVICE DT_LABEL(DT_INST(0, nxp_imx_flexspi_nor))
#define FLASH_TEST_REGION_OFFSET FLASH_AREA_OFFSET(storage)
#define TEST_AREA_MAX ((FLASH_AREA_SIZE(storage)) + (FLASH_TEST_REGION_OFFSET))
+#elif defined(CONFIG_FLASH_MCUX_FLEXSPI_MX25UM51345G)
+
+#define FLASH_DEVICE DT_LABEL(DT_INST(0, nxp_imx_flexspi_mx25um51345g))
+#define FLASH_TEST_REGION_OFFSET FLASH_AREA_OFFSET(storage)
+#define TEST_AREA_MAX ((FLASH_AREA_SIZE(storage)) + (FLASH_TEST_REGION_OFFSET))
#else
/* SoC emebded NVM */
diff --git a/tests/drivers/flash/testcase.yaml b/tests/drivers/flash/testcase.yaml
index 88ca925..4f66f6d 100644
--- a/tests/drivers/flash/testcase.yaml
+++ b/tests/drivers/flash/testcase.yaml
@@ -12,7 +12,7 @@
integration_platforms:
- nrf52840dk_nrf52840
drivers.flash.default:
- platform_allow: mimxrt1060_evk it8xxx2_evb
+ platform_allow: mimxrt1060_evk it8xxx2_evb mimxrt685_evk_cm33
tags: mcux
integration_platforms:
- mimxrt1060_evk