28 lines
311 B
C
28 lines
311 B
C
#include <stdlib.h>
|
|
#include <stdio.h>
|
|
|
|
size_t ft_strlen(char *str);
|
|
|
|
void test_strlen(void)
|
|
{
|
|
int nb_tests;
|
|
int passed;
|
|
|
|
nb_tests = 3;
|
|
passed = 0;
|
|
|
|
if(ft_strlen("hello") == 5)
|
|
passed++;
|
|
if(ft_strlen("") == 0)
|
|
passed++;
|
|
if(ft_strlen(NULL) == 0)
|
|
passed++;
|
|
|
|
|
|
}
|
|
|
|
int main(void)
|
|
{
|
|
test_strlen();
|
|
}
|