summaryrefslogtreecommitdiff
path: root/src/testing.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/testing.c')
-rw-r--r--src/testing.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/src/testing.c b/src/testing.c
index 917ad45..f3239e0 100644
--- a/src/testing.c
+++ b/src/testing.c
@@ -11,8 +11,8 @@
#define COLOUR_GREEN "\033[0;32m"
#define COLOUR_YELLOW "\033[0;33m"
-static const char *const
-ENVVAR_NAME = "NO_COLOUR";
+static const char
+ENVVAR_NAME[] = "NO_COLOUR";
static bool
@@ -24,8 +24,6 @@ show_colour(void) {
void
test_start(const char *const name) {
(void)fprintf(stderr, "%s:\n", name);
-
- return;
}
void
@@ -33,7 +31,7 @@ testing(const char *const message) {
if (show_colour()) {
(void)fprintf(
stderr,
- COLOUR_YELLOW "testing" COLOUR_RESET ": %s...",
+ COLOUR_YELLOW "testing" COLOUR_RESET ": %s... ",
message
);
} else {
@@ -43,17 +41,13 @@ testing(const char *const message) {
message
);
}
-
- return;
}
void
test_ok(void) {
if (show_colour()) {
- (void)fprintf(stderr, " " COLOUR_GREEN "OK" COLOUR_RESET ".\n");
+ (void)fprintf(stderr, COLOUR_GREEN "OK" COLOUR_RESET ".\n");
} else {
(void)fprintf(stderr, " OK.\n");
}
-
- return;
}