Skip to content

Commit f68da80

Browse files
committed
fix: ci improvements - test paths and llvm detection retry
1 parent d21269b commit f68da80

File tree

3 files changed

+14
-5
lines changed

3 files changed

+14
-5
lines changed

scripts/setup_llvm_windows.ps1

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,16 @@ if (-not $layout) {
8686
Write-Host "Refreshing PATH..."
8787
$env:PATH = [System.Environment]::GetEnvironmentVariable("Path","Machine") + ";" + [System.Environment]::GetEnvironmentVariable("Path","User")
8888

89-
$layout = Resolve-LLVMLayout
89+
# Retry detection loop
90+
for ($i = 1; $i -le 3; $i++) {
91+
Write-Host "Retrying LLVM detection (Attempt $i/3)..."
92+
$layout = Resolve-LLVMLayout
93+
if ($layout) { break }
94+
if ($i -lt 3) {
95+
Write-Host "Waiting 5 seconds before next attempt..."
96+
Start-Sleep -Seconds 5
97+
}
98+
}
9099
}
91100

92101
# 3. Export findings

tests/bytecode_tests.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ int main(void) {
3232
printf("OP_CONSTANT: %d, OP_NOP: %d\n", OP_CONSTANT, OP_NOP);
3333

3434
/* Create an example hello chunk and write to file */
35-
const char *outpath = "examples/hello.proxbc";
35+
const char *outpath = "hello.proxbc";
3636
if (example_write_hello(outpath) == 0) {
3737
printf("Wrote example chunk to %s\n", outpath);
3838
} else {
@@ -65,7 +65,7 @@ int main(void) {
6565
example_create_hello_blob(&buf, &buflen);
6666
if (buf && buflen) {
6767
/* write to temporary file to reuse loader */
68-
const char *tmp = "examples/hello_blob.proxbc";
68+
const char *tmp = "hello_blob.proxbc";
6969
FILE *f = fopen(tmp,"wb");
7070
if (f) { fwrite(buf,1,buflen,f); fclose(f); printf("Wrote blob to %s\n", tmp); }
7171
free(buf);

tests/test_opcode_roundtrip.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#include <string.h>
1515
#include <assert.h>
1616
#include "bytecode.h"
17-
#include "../include/vm.h"
17+
#include "vm.h"
1818

1919
#include "../include/value.h"
2020
#include "../include/object.h"
@@ -24,7 +24,7 @@
2424

2525
int main(void) {
2626
initVM(&vm);
27-
const char *tmp = "tests/tmp_opcode_rt.proxbc";
27+
const char *tmp = "tmp_opcode_rt.proxbc";
2828

2929
Chunk c;
3030
initChunk(&c);

0 commit comments

Comments
 (0)