File: runtest.h

package info (click to toggle)
wdm 1.28-3
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 2,108 kB
  • ctags: 1,140
  • sloc: ansic: 11,448; sh: 1,431; makefile: 441; perl: 29; cpp: 10
file content (19 lines) | stat: -rw-r--r-- 343 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/**
 * Copyright (C) 2002, 2003 Alexey Voinov <voins@voins.program.ru>
 *
 * @file
 *     
 */
#ifndef __RUNTEST_H
#define __RUNTEST_H
#include <stdio.h>

#define test_assert(x) \
	if(!(x)) \
	{ \
		printf("assertion failed: %s in line %i\n", #x, __LINE__); \
		return 0; \
	}

#endif /* __RUNTEST_H */