This adds regression tests for issue #3337pull/3339/head
parent
b4aee4675a
commit
ad2ab56e5f
6 changed files with 40 additions and 8 deletions
@ -1,8 +1,8 @@ |
||||
project('D Unittests', 'd') |
||||
|
||||
e = executable('dapp', 'app.d', install : true) |
||||
e = executable('dapp', ['app.d', 'second_unit.d'], install : true) |
||||
test('dapp_run', e, should_fail: true) |
||||
|
||||
e_test = executable('dapp_test', 'app.d', |
||||
d_args: meson.get_compiler('d').unittest_args()) |
||||
e_test = executable('dapp_test', ['app.d', 'second_unit.d'], |
||||
d_unittest: true) |
||||
test('dapp_test', e_test) |
||||
|
@ -0,0 +1,10 @@ |
||||
|
||||
void secondModuleTestFunc () |
||||
{ |
||||
import std.stdio : writeln; |
||||
|
||||
version (unittest) |
||||
writeln ("Hello!"); |
||||
else |
||||
assert (0); |
||||
} |
@ -0,0 +1,9 @@ |
||||
|
||||
auto secondModulePeopleVersionSet () |
||||
{ |
||||
version (With_People) { |
||||
return true; |
||||
} else { |
||||
return false; |
||||
} |
||||
} |
Loading…
Reference in new issue