Build_src_filter behavior on files out of src folder

Hello there, I have the following folder structure in my project:


├── .vscode
│   ├── c_cpp_properties.json
│   ├── extensions.json
│   ├── launch.json
│   └── settings.json
├── include
│   └── README
├── lib
│   └── c_buffer
│       ├── c_buffer.c
│       └── c_buffer.h
├── platformio.ini
├── src
│   ├── main.c
│   └── main.h
├── test
│   ├── test_circular_buffer_f401re.c
│   ├── test_circular_buffer_native.c
│   ├── unity_config.c
│   └── unity_config.h
└── workspaceToText.txt

I’m trying to get 2 different test builds, one for native (windows MinGW) and another for Nucleo F401RE board (arm-gcc). My logic is as follows:

I just want to include the corresponding test file (*_native/f401re) and remove unity config in case I’m testing my native env. When using the nucleo, I want to filter out the native test. I’m currently using build_src_filter, but to no avail. I’ve tried /, , // as the path separator, but nothing. It won’t filter out those files, so the project can’t build correctly. I haven’t modified the default path for build_src_filter, so it should default to my /src folder, in the same level as /test.

Am I overlooking something obvious here? Is build_src_filter intended to be used in other way or only for files under the /src? I really can’t tell. Any help is appreciated!

My platformio.ini is as follows:

platform = native
debug_test = *
build_flags = 
build_src_filter =

platform = ststm32	
framework = stm32cube
board = nucleo_f401re
debug_test = *
build_src_filter =	
build_flags = 	

Use the correct testing structure with embedded, common and native tests. See

And corresponding test_ignore lines in

That was it, thanks so much!