Skip to content

Commit c466d85

Browse files
committed
add clojure and fix testcases
1 parent 572db6d commit c466d85

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

src/main/clojure/skiverse/main.clj

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
(ns skiverse.main
2+
(:import skiverse.ParticleSystem)
23
(:require [clojure.tools.logging :as log])
34
(:gen-class))
45

56
(defn -main []
6-
)
7+
(ParticleSystem/main (make-array java.lang.String 0)))

src/tests/java/ski/SKITest.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,10 @@ void testSelfApplication() {
158158
@Test
159159
void testChain() {
160160
Combinator chain = cons(cons(iota(), cons(cons(cons(iota(), cons(cons(S(), iota()), iota())), iota()), iota())), var("x"));
161-
chain.supply(new Potential(256.0));
162161
assertEquals("((ι, (((ι, ((S, ι), ι)), ι), ι)), x)", chain.script());
162+
chain.supply(new Potential(7.0));
163+
assertEquals("((ι, (((ι, ((S, ι), ι)), ι), ι)), x)", chain.eval().script());
164+
chain.supply(new Potential(8.0));
163165
assertEquals("((((((ι, ((S, ι), ι)), ι), ι), S), K), x)", chain.eval().script());
164166
}
165167

0 commit comments

Comments
 (0)