You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[NPU] Simplify folder structure for NPU functional tests (#32298)
### Details:
- Added `folder structure` and `developing convention` sections to the
tests README.
- Moved headers from `overload` directory to `behavior` directory.
- Moved some infer request files from the root `behavior` directory to
`behavior/ov_infer_request` dir.
- Moved NPU test instantiations from `shared_tests_instances` directory
to `behavior` directory.
- Added missing `#pragma once` directives to some headers.
- Renamed `functions.h` into `functions.hpp`.
- Made small nitpicks to the test files that are already modified by one
of the actions above. Nitpicks include: removing pointless comments,
`SKIP_IF_CURRENT_TEST_IS_DISABLED()` call correctness, removing unused
headers, and wrapping test instantiations in anonymous namespaces.
### Tickets:
- *C-174556*
---------
Signed-off-by: alexandruenache1111 <[email protected]>
Copy file name to clipboardExpand all lines: src/plugins/intel_npu/tests/functional/README.md
+33Lines changed: 33 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -54,3 +54,36 @@ By default, the environment variable `OV_NPU_TESTS_SKIP_CONFIG_FILE` is set to f
54
54
Skip filters can be enabled/disabled according to rules defining the device, backend or operating system, depending on where tests are supposed to run.
55
55
Rules are optional, multiple rules can be chained together. Users can negate a rule by using "!".
56
56
When determining if a skip filter is active, rules across different categories (backend, device, operating_system) are combined using an AND operation. While multiple entries of the same category will use an OR operation.
57
+
58
+
## Folder structure
59
+
60
+
### Behavior
61
+
The folder structure of the `behavior` directory follows the folder structure of the OpenVINO base tests.
62
+
63
+
The OpenVINO convention requires the tests to be organized in at least three directories: `compiled_model`, `ov_infer_request`, and `ov_plugin`. If the scope of NPU Plugin tests becomes broader, additional directories may be created.
64
+
65
+
The E2E tests reside here.
66
+
67
+
### Common
68
+
The place of utility functions and `getTestCaseName` base implementations.
69
+
70
+
### Internal
71
+
The folder structure is mirrored from the one in the `intel_npu/src` directory.
72
+
73
+
The NPU implementations of test classes and their corresponding tests are located here.
74
+
75
+
### Shared tests instances
76
+
OpenVINO test instantiations using NPU Plugin's own arguments.
77
+
78
+
## Test developing convention
79
+
80
+
Any test should be split into a `.hpp` and `.cpp` file, with the exception of the tests from `shared_tests_instances`, which don't need `.hpp` files. A test's `.hpp` file should be located in the same directory as its `.cpp` file.
81
+
82
+
The `.hpp` file should have the entirety of its contents wrapped around the `ov::test::behavior` namespace.
83
+
The contents are:
84
+
- class declarations
85
+
- methods/functions definitions
86
+
- test definitions
87
+
- aliases
88
+
89
+
The `.cpp` file contains the test instantiations and the variables passed as arguments. The contents should be wrapped around an anonymous/unnamed namespace.
0 commit comments