Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/remove datomic #10

Merged
merged 2 commits into from
Jan 26, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions deps.edn
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
{:paths ["src"]
:deps {edn-query-language/eql {:mvn/version "0.0.9"}
aysylu/loom {:mvn/version "1.0.2"}
com.datomic/datomic-free {:mvn/version "0.9.5697"
:exclusions [commons-codec
joda-time]}}
aysylu/loom {:mvn/version "1.0.2"}}

:aliases {:provided {:extra-deps {org.clojure/clojure {:mvn/version "1.10.1"}
org.clojure/clojurescript {:mvn/version "1.10.597"}}}
:test {:extra-paths ["test" "dev"]
:extra-deps {com.cognitect/test-runner {:git/url "https://github.com/cognitect-labs/test-runner.git"
:extra-deps {com.datomic/datomic-free {:mvn/version "0.9.5697"
:exclusions [joda-time
commons-codec]}
com.cognitect/test-runner {:git/url "https://github.com/cognitect-labs/test-runner.git"
:sha "f7ef16dc3b8332b0d77bc0274578ad5270fbfedd"}}
:main-opts ["-m" "cognitect.test-runner"]}}}
5 changes: 2 additions & 3 deletions src/pour/core.clj
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
(ns pour.core
(:require [edn-query-language.core :as eql])
(:import (clojure.lang Seqable)
(datomic Entity)))
(:import (clojure.lang Seqable)))

(defn seqy? [s]
(and (not (instance? Entity s))
(and (not (:db/id s)) ; ie, a datomic Entity or similar
(not (map? s))
(instance? Seqable s)))

Expand Down
1 change: 1 addition & 0 deletions test/pour/core_test.clj
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
(defrecord Test [a b])

(deftest seqy
(is (not (pour/seqy? {:db/id 123})))
(is (not (pour/seqy? {})))
(is (not (pour/seqy? nil)))
(is (not (pour/seqy? "hi")))
Expand Down