From 66a806f9c67c1bb5afe91822c4bb7fd7e2f62401 Mon Sep 17 00:00:00 2001 From: Muhammad Farhan Date: Mon, 14 Jul 2025 12:28:18 +0400 Subject: [PATCH] Add edge case test for ft_iterative_power(0, 0) --- mini-moul/tests/C05/ex02/ft_iterative_power.c | 6 ++++++ mini-moul/tests/C05/ex03/ft_recursive_power.c | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/mini-moul/tests/C05/ex02/ft_iterative_power.c b/mini-moul/tests/C05/ex02/ft_iterative_power.c index 7164ba3..bbe2007 100644 --- a/mini-moul/tests/C05/ex02/ft_iterative_power.c +++ b/mini-moul/tests/C05/ex02/ft_iterative_power.c @@ -18,6 +18,12 @@ int run_tests(t_test *tests, int count); int main(void) { t_test tests[] = { + { + .desc = "0 power 0 (edge case)", + .base = 0, + .power = 0, + .expected = 1, + }, { .desc = "Power of 0", .base = 10, diff --git a/mini-moul/tests/C05/ex03/ft_recursive_power.c b/mini-moul/tests/C05/ex03/ft_recursive_power.c index 8c58f96..d235101 100644 --- a/mini-moul/tests/C05/ex03/ft_recursive_power.c +++ b/mini-moul/tests/C05/ex03/ft_recursive_power.c @@ -18,6 +18,12 @@ int run_tests(t_test *tests, int count); int main(void) { t_test tests[] = { + { + .desc = "0 power 0 (edge case)", + .base = 0, + .power = 0, + .expected = 1, + }, { .desc = "Power of 0", .base = 10,