Skip to content

Commit 94a0511

Browse files
committed
WIP test
1 parent 66eb75e commit 94a0511

File tree

3 files changed

+65
-6
lines changed

3 files changed

+65
-6
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
(in-package :cl-user)
2+
3+
#+sbcl
4+
(require :asdf)
5+
6+
(load "/tmp/ql-dir/quicklisp.lisp")
7+
(quicklisp-quickstart:install)
8+
9+
(load "/home/runner/work/cl-python/cl-python/clpython.asd")
10+
11+
(ql:quickload :cl-python)
12+
(ql:quickload :cl-python-test)
13+
14+
(asdf:test-system "clpython")

.github/workflows/run-tests.yaml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: build & test
2+
on:
3+
push:
4+
branches:
5+
- master
6+
- dev
7+
jobs:
8+
9+
install_quicklisp:
10+
name: Install QuickLisp
11+
runs-on: ubuntu-latest
12+
steps:
13+
- run: |
14+
cd /tmp
15+
mkdir ql-dir
16+
cd ql-dir
17+
wget -q https://beta.quicklisp.org/quicklisp.lisp
18+
chmod -R a+rwx /tmp/ql-dir
19+
- name: Upload Quicklisp artifact
20+
uses: actions/upload-artifact@v4
21+
with:
22+
name: ql-artifact
23+
path: /tmp/ql-dir
24+
25+
run_test_suites:
26+
name: Test on ${{ matrix.scenario }}
27+
runs-on: ubuntu-latest
28+
strategy:
29+
matrix:
30+
scenario: [sbcl]
31+
needs: [install_quicklisp]
32+
steps:
33+
- uses: actions/checkout@v4
34+
35+
- uses: actions/download-artifact@v4
36+
with:
37+
name: ql-artifact
38+
path: /tmp/ql-dir
39+
40+
- if: matrix.scenario == 'sbcl'
41+
run: |
42+
sudo apt-get install sbcl
43+
sbcl --script /home/runner/work/cl-python/cl-python/.github/workflows/github-workflow-tests.lisp

clpython.asd

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212
(eval-when (:compile-toplevel)
1313
(error "This ASDF file should be run interpreted."))
1414

15+
(eval-when (compile load eval)
16+
(import '(asdf:defsystem asdf:load-op asdf:test-op)))
1517

1618
;;; CL-Python is split into several ASDF systems, to make it possible to load
1719
;;; specific components -- in particular, to load the compiler or parser without
@@ -31,7 +33,7 @@
3133
(muffle-warning c))))))
3234
(funcall thunk)))
3335

34-
(defsystem "clpython/basic"
36+
(asdf:defsystem "clpython/basic"
3537
:description "CLPython package and utils"
3638
:depends-on ("closer-mop")
3739
:serial t
@@ -53,7 +55,7 @@
5355
(when (asdf:find-system "yacc" nil)
5456
(pushnew :have-cl-yacc *features*))
5557

56-
(defsystem "clpython/parser"
58+
(asdf:defsystem "clpython/parser"
5759
:description "Python parser, code walker, and pretty printer"
5860
:depends-on ("clpython/basic"
5961
"closer-mop"
@@ -68,7 +70,7 @@
6870
(:file "walk" )
6971
(:file "pprint" )))))
7072

71-
(defsystem "clpython/compiler"
73+
(asdf:defsystem "clpython/compiler"
7274
:description "Python compiler"
7375
:depends-on ("clpython/basic" "clpython/parser" "clpython/runtime" "closer-mop")
7476
:serial t
@@ -81,7 +83,7 @@
8183
(:file "generator" )
8284
(:file "optimize" )))))
8385

84-
(defsystem "clpython/runtime"
86+
(asdf:defsystem "clpython/runtime"
8587
:description "Python runtime environment"
8688
:depends-on ("clpython/basic" "closer-mop" #+(or abcl clisp ecl) "cl-custom-hash-table" "cl-fad")
8789
:components ((:module "runtime"
@@ -96,7 +98,7 @@
9698
(:file "run" )
9799
(:file "import" )))))
98100

99-
(defsystem "clpython/lib"
101+
(asdf:defsystem "clpython/lib"
100102
:description "Python module library"
101103
:depends-on ("clpython/basic" "clpython/runtime" "clpython/compiler" #| TODO: remove compiler dep |#)
102104
:components ((:module "lib"
@@ -141,7 +143,7 @@
141143
(:file "time" :depends-on ("lsetup"))
142144
(:file "_weakref" :depends-on ("lsetup"))))))
143145

144-
(defsystem "clpython/contrib"
146+
(asdf:defsystem "clpython/contrib"
145147
:description "CLPython contributions and experiments"
146148
:depends-on ("clpython/basic" "clpython/runtime" "clpython/compiler")
147149
:components ((:module "contrib"

0 commit comments

Comments
 (0)