Skip to contentSkip to conversation

lib/test_list: Follow existing pattern for a file name

PATCH In review Andy Shevchenko 1 participant 2 messages Oct 15, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lib/test_list: Follow existing pattern for a file name

Test in lib/ either KUnit or not are named in the same pattern, i.e. test_*.c, except few ones. Rename list-test.c to test_list.c to follow this pattern.

Note, current documentation doesn't specify any file name conventions, and we glad to stick with a current one in the subsystem.

---
 lib/Makefile                     | 4 ++--
 lib/{list-test.c => test_list.c} | 0
 2 files changed, 2 insertions(+), 2 deletions(-)
 rename lib/{list-test.c => test_list.c} (100%)
lib/Makefile +2 -2
index 5ca03ba6ee45..e71abeea4a3e 100644
@@ -350,6 +350,6 @@ obj-$(CONFIG_PLDMFW) += pldmfw/
 
 # KUnit tests
 obj-$(CONFIG_BITFIELD_KUNIT) += bitfield_kunit.o
-obj-$(CONFIG_LIST_KUNIT_TEST) += list-test.o
-obj-$(CONFIG_LINEAR_RANGES_TEST) += test_linear_ranges.o
 obj-$(CONFIG_BITS_TEST) += test_bits.o
+obj-$(CONFIG_LINEAR_RANGES_TEST) += test_linear_ranges.o
+obj-$(CONFIG_LIST_KUNIT_TEST) += test_list.o
lib/test_list.c renamed from lib/list-test.c +0 -0
similarity index 100%
rename from lib/list-test.c
rename to lib/test_list.c
Signature · 1 line
2.28.0
#1 lore raw
Quoted 6 lines · Andy Shevchenko

Test in lib/ either KUnit or not are named in the same pattern, i.e. test_*.c, except few ones. Rename list-test.c to test_list.c to follow this pattern.

Note, current documentation doesn't specify any file name conventions, and we glad to stick with a current one in the subsystem.

Okay, according to new convention it should be either _test or _kunit. Still not clear where to put it. New convention tell about nearby to the module it tests, but this is header file!

Please, update documentation accordingly.

Signature · 2 lines
With Best Regards,
Andy Shevchenko