summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@gmail.com>2009-07-09 16:24:13 +0000
committerTavian Barnes <tavianator@gmail.com>2009-07-09 16:24:13 +0000
commit9a634a53f0d7135ef82e6888a89091db173c7f7f (patch)
treeb424545f9ad05288f6d94048bea5fc48e90aeff0 /tests
parent28de29088084e5f544b79760748ef28739b5c769 (diff)
downloaddimension-9a634a53f0d7135ef82e6888a89091db173c7f7f.tar.xz
Code formatting.
Diffstat (limited to 'tests')
-rw-r--r--tests/tests.c4
-rw-r--r--tests/testsxx.cpp4
-rw-r--r--tests/warning.c16
3 files changed, 16 insertions, 8 deletions
diff --git a/tests/tests.c b/tests/tests.c
index cbf7ff8..3696216 100644
--- a/tests/tests.c
+++ b/tests/tests.c
@@ -267,8 +267,8 @@ dmnsn_progressbar_async(const char *str, const dmnsn_progress *progress)
/* Create the worker thread */
if (pthread_create(&barprogress->thread, NULL, &dmnsn_progressbar_thread,
- payload)
- != 0) {
+ payload) != 0)
+ {
dmnsn_error(DMNSN_SEVERITY_HIGH,
"Couldn't start progress bar background thread.");
}
diff --git a/tests/testsxx.cpp b/tests/testsxx.cpp
index 908d0f8..aaeb546 100644
--- a/tests/testsxx.cpp
+++ b/tests/testsxx.cpp
@@ -116,8 +116,8 @@ namespace Dimension
/* Create the worker thread */
if (pthread_create(&barprogress->thread, NULL, &progressbar_thread,
- reinterpret_cast<void*>(payload))
- != 0) {
+ reinterpret_cast<void*>(payload)) != 0)
+ {
throw Dimension_Error("Couldn't create background thread.");
}
diff --git a/tests/warning.c b/tests/warning.c
index 9b8ba12..7b6aac3 100644
--- a/tests/warning.c
+++ b/tests/warning.c
@@ -25,18 +25,26 @@
int
main()
{
- if (dmnsn_get_resilience() != DMNSN_SEVERITY_MEDIUM) return EXIT_FAILURE;
+ if (dmnsn_get_resilience() != DMNSN_SEVERITY_MEDIUM) {
+ return EXIT_FAILURE;
+ }
dmnsn_set_resilience(DMNSN_SEVERITY_LOW);
- if (dmnsn_get_resilience() != DMNSN_SEVERITY_LOW) return EXIT_FAILURE;
+ if (dmnsn_get_resilience() != DMNSN_SEVERITY_LOW) {
+ return EXIT_FAILURE;
+ }
dmnsn_set_resilience(DMNSN_SEVERITY_MEDIUM);
- if (dmnsn_get_resilience() != DMNSN_SEVERITY_MEDIUM) return EXIT_FAILURE;
+ if (dmnsn_get_resilience() != DMNSN_SEVERITY_MEDIUM) {
+ return EXIT_FAILURE;
+ }
dmnsn_error(DMNSN_SEVERITY_LOW, "This warning is expected.");
dmnsn_set_resilience(DMNSN_SEVERITY_HIGH);
- if (dmnsn_get_resilience() != DMNSN_SEVERITY_HIGH) return EXIT_FAILURE;
+ if (dmnsn_get_resilience() != DMNSN_SEVERITY_HIGH) {
+ return EXIT_FAILURE;
+ }
dmnsn_error(DMNSN_SEVERITY_LOW, "This warning is expected.");
dmnsn_error(DMNSN_SEVERITY_MEDIUM, "This warning is expected.");