File tree Expand file tree Collapse file tree 5 files changed +21
-24
lines changed
Expand file tree Collapse file tree 5 files changed +21
-24
lines changed Original file line number Diff line number Diff line change 99 ]
1010 }
1111 },
12+ "features" : {
13+ "ghcr.io/devcontainers/features/docker-in-docker:2" : {}
14+ },
1215 "postCreateCommand" : " rustup show"
1316}
Original file line number Diff line number Diff line change @@ -26,32 +26,12 @@ jobs:
2626 permissions :
2727 contents : read
2828 env :
29+ # see tests/thrust-pcsat-wrapper
2930 COAR_IMAGE : ghcr.io/hiroshi-unno/coar@sha256:73144ed27a02b163d1a71b41b58f3b5414f12e91326015600cfdca64ff19f011
3031 steps :
3132 - uses : actions/checkout@v4
3233 - uses : ./.github/actions/setup-z3
33- - name : Setup thrust-pcsat-wrapper
34- run : |
35- docker pull "$COAR_IMAGE"
36-
37- cat <<"EOF" > thrust-pcsat-wrapper
38- #!/bin/bash
39-
40- smt2=$(mktemp -p . --suffix .smt2)
41- trap "rm -f $smt2" EXIT
42- cp "$1" "$smt2"
43- out=$(
44- docker run --rm -v "$PWD:/mnt" -w /root/coar "$COAR_IMAGE" \
45- main.exe -c ./config/solver/pcsat_tbq_ar.json -p pcsp "/mnt/$smt2"
46- )
47- exit_code=$?
48- echo "${out%,*}"
49- exit "$exit_code"
50- EOF
51- chmod +x thrust-pcsat-wrapper
52-
53- mkdir -p ~/.local/bin
54- mv thrust-pcsat-wrapper ~/.local/bin/thrust-pcsat-wrapper
34+ - run : docker pull "$COAR_IMAGE"
5535 - run : rustup show
5636 - uses : Swatinem/rust-cache@v2
5737 - run : cargo test
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ COAR_IMAGE=${COAR_IMAGE:- ghcr.io/ hiroshi-unno/ coar: main}
4+
5+ smt2=$( mktemp -p . --suffix .smt2)
6+ trap " rm -f $smt2 " EXIT
7+ cp " $1 " " $smt2 "
8+ out=$(
9+ docker run --rm -v " $PWD :/mnt" -w /root/coar " $COAR_IMAGE " \
10+ main.exe -c ./config/solver/pcsat_tbq_ar.json -p pcsp " /mnt/$smt2 "
11+ )
12+ exit_code=$?
13+ echo " ${out% ,* } "
14+ exit " $exit_code "
Original file line number Diff line number Diff line change 11//@error-in-other-file: Unsat
22//@compile-flags: -C debug-assertions=off
3- //@rustc-env: THRUST_SOLVER=thrust-pcsat-wrapper
3+ //@rustc-env: THRUST_SOLVER=tests/ thrust-pcsat-wrapper
44
55#[ thrust:: trusted]
66#[ thrust:: callable]
Original file line number Diff line number Diff line change 11//@check-pass
22//@compile-flags: -C debug-assertions=off
3- //@rustc-env: THRUST_SOLVER=thrust-pcsat-wrapper
3+ //@rustc-env: THRUST_SOLVER=tests/ thrust-pcsat-wrapper
44
55#[ thrust:: trusted]
66#[ thrust:: callable]
You can’t perform that action at this time.
0 commit comments