| ... | ... | @@ -485,7 +485,12 @@ pub fn lowerToBuildSteps( |
| 485 | 485 | } |
| 486 | 486 | const root_source_file = writefiles.getFileSource(update.files.items[0].path).?; |
| 487 | 487 | |
| 488 | | const artifact = switch (case.output_mode) { |
| 488 | const artifact = if (case.is_test) b.addTest(.{ |
| 489 | .root_source_file = root_source_file, |
| 490 | .name = case.name, |
| 491 | .target = case.target, |
| 492 | .optimize = case.optimize_mode, |
| 493 | }) else switch (case.output_mode) { |
| 489 | 494 | .Obj => b.addObject(.{ |
| 490 | 495 | .root_source_file = root_source_file, |
| 491 | 496 | .name = case.name, |
| ... | ... | @@ -498,12 +503,7 @@ pub fn lowerToBuildSteps( |
| 498 | 503 | .target = case.target, |
| 499 | 504 | .optimize = case.optimize_mode, |
| 500 | 505 | }), |
| 501 | | .Exe => if (case.is_test) b.addTest(.{ |
| 502 | | .root_source_file = root_source_file, |
| 503 | | .name = case.name, |
| 504 | | .target = case.target, |
| 505 | | .optimize = case.optimize_mode, |
| 506 | | }) else b.addExecutable(.{ |
| 506 | .Exe => b.addExecutable(.{ |
| 507 | 507 | .root_source_file = root_source_file, |
| 508 | 508 | .name = case.name, |
| 509 | 509 | .target = case.target, |