syle: norm

This commit is contained in:
airone01
2026-01-24 18:56:42 +01:00
parent 932732c1e5
commit 1ee5334149
17 changed files with 108 additions and 160 deletions

View File

@@ -12,17 +12,16 @@
#include "../tests.h"
int strlen_launcher(void) {
t_unit_test *testlist;
size_t res;
int strlen_launcher(void)
{
t_unit_test *testlist;
size_t res;
testlist = NULL;
load_test(&testlist, "null", &test_null);
load_test(&testlist, "basic", &test_basic);
load_test(&testlist, "large", &test_large);
res = launch_tests(testlist, "strlen");
clear_tests(&testlist);
return (res);
testlist = NULL;
load_test(&testlist, "null", &test_null);
load_test(&testlist, "basic", &test_basic);
load_test(&testlist, "large", &test_large);
res = launch_tests(testlist, "strlen");
clear_tests(&testlist);
return (res);
}

View File

@@ -12,6 +12,7 @@
#include "../tests.h"
int test_null(void) {
return (ft_strlen(NULL) == 0);
int test_null(void)
{
return (ft_strlen(NULL) == 0);
}

View File

@@ -12,14 +12,16 @@
#include "../tests.h"
int test_large(void) {
size_t i;
char s[10000];
int test_large(void)
{
size_t i;
char s[10000];
i = 0;
while (i < sizeof(s)) {
s[i] = ' ';
i++;
}
return (ft_strlen(s) == sizeof(s) + 1);
i = 0;
while (i < sizeof(s))
{
s[i] = ' ';
i++;
}
return (ft_strlen(s) == sizeof(s) + 1);
}