Skip to content

Weird exception when a string starts with a / #19

@viebel

Description

@viebel

When a fact checks a string that starts with a /, an exception is thrown

Full repro:

Clojure 1.10.1
midje-nrepl 1.2.0-snapshot

/usr/local/bin/lein update-in :dependencies conj \[nrepl\ \"0.7.0\"\] -- update-in :plugins conj \[cider/cider-nrepl\ \"0.25.1\"\] -- update-in :plugins conj \[nubank/midje-nrepl\ \"1.2.0-snapshot\"\] -- repl 

nREPL server started on port 63847 on host 127.0.0.1 - nrepl://127.0.0.1:63847
REPL-y 0.4.4, nREPL 0.7.0
Clojure 1.10.1
Java HotSpot(TM) 64-Bit Server VM 1.8.0_121-b13
    Docs: (doc function-name-here)
          (find-doc "part-of-name-here")
  Source: (source function-name-here)
 Javadoc: (javadoc java-object-or-class-here)
    Exit: Control+D or (exit) or (quit)
 Results: Stored in vars *1, *2, *3, an exception in *e


user=> (use 'midje.repl)
nil
user=> (fact (identity "/gql") => "/gql" )

Syntax error macroexpanding clojure.core/defn at (target/b85b0c8b9ab53121a9a5c5886ffbb788ae0678fc-init.clj:1:1).
(identity "/gql")17819 - failed: simple-symbol? at: [:fn-name] spec: :clojure.core.specs.alpha/defn-args

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions