Skip to content

Commit

Permalink
Enable unittest blocks in d_do_test.d
Browse files Browse the repository at this point in the history
  • Loading branch information
9rnsr committed Dec 27, 2012
1 parent 6c7fa39 commit 87a0d4d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions test/Makefile
Expand Up @@ -198,5 +198,6 @@ start_fail_compilation_tests: $(RESULTS_DIR)/.created $(RESULTS_DIR)/d_do_test
$(RESULTS_DIR)/d_do_test: d_do_test.d $(RESULTS_DIR)/.created
@echo "Building d_do_test tool"
@echo "OS: $(OS)"
$(QUIET)$(DMD) -m$(MODEL) -unittest -run d_do_test.d -unittest
$(QUIET)$(DMD) -m$(MODEL) -od$(RESULTS_DIR) -of$(RESULTS_DIR)$(DSEP)d_do_test d_do_test.d

8 changes: 5 additions & 3 deletions test/d_do_test.d
Expand Up @@ -137,7 +137,7 @@ void gatherTestParameters(ref TestArgs testArgs, string input_dir, string input_
findTestParameter(file, "REQUIRED_ARGS", testArgs.requiredArgs);
if(envData.required_args.length)
testArgs.requiredArgs ~= " " ~ envData.required_args;

if (! findTestParameter(file, "PERMUTE_ARGS", testArgs.permuteArgs))
{
if (testArgs.mode != TestMode.FAIL_COMPILE)
Expand Down Expand Up @@ -284,6 +284,8 @@ int main(string[] args)
{
if (args.length != 4)
{
if (args.length == 2 && args[1] == "-unittest")
return 0;
usage();
return 1;
}
Expand Down Expand Up @@ -407,8 +409,8 @@ int main(string[] args)
if (testArgs.mode == TestMode.RUN)
{
toCleanup ~= test_app_dmd;
version(Windows)
if(envData.model == "64")
version(Windows)
if (envData.model == "64")
{
toCleanup ~= test_app_dmd_base ~ to!string(i) ~ ".ilk";
toCleanup ~= test_app_dmd_base ~ to!string(i) ~ ".pdb";
Expand Down

0 comments on commit 87a0d4d

Please sign in to comment.