Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered Quality
Clojure@seleniumconf
1. September 11, 2014
Contents
1 First things first: what is Clojure? 2
2 Clojure Syntax 4
3 Dynamic Develoment 4
4 Functional Programming 4
5 Example 4
6 Example Cont. 5
7 Example Cont. 5
1
2. 8 Example Cont. 5
9 Hosted on the JVM 5
10 Macros in Clojure 6
11 Clj-webdriver 6
12 calabash-clj 6
13 appium-clj 7
14 Demo 8
15 Any Questions? 9
1 First things first: what is Clojure?
• Invented in 2007 by
2
3. Rich Hickey
• Dynamic, functional programming language
• Lisp for JVM
3
4. 2 Clojure Syntax
3 Dynamic Develoment
4 Functional Programming
• Functions as first-class objects
• Feedback loop is fast
5 Example
4
5. 6 Example Cont.
7 Example Cont.
8 Example Cont.
9 Hosted on the JVM
• Designed to be hosted (JVM, V8, CLR, Python, LLVM, etc)
• Great java library consumer
• Java invocation syntax is clean and simple Ex.:
5
6. -> (. Classname-symbol method-symbol args*)
-> (.instanceMember Classname args*)
10 Macros in Clojure
• Macros gives clojure great power.
• Difference between functions and macros
• Writing control flow macro
11 Clj-webdriver
• Clojure API for selenium webdriver
• https://github.com/semperos/clj-webdriver
• Clojars https://clojars.org/me.kapilreddy/clj-webdriver
• Features
• Demo link: https://www.youtube.com/watch?v=Zje19PkLbYk&feature=
youtu.be
12 calabash-clj
• Clojure API for Android
• https://github.com/kapilreddy/calabash-clj
6
7. Kapil Reddy [Helpshift]
• Demo link: https://www.youtube.com/watch?v=NY6aQh0lf8M&feature=
youtu.be
13 appium-clj
• Clojure API for appium-java-client
• https://github.com/helpshift/appium-clj-client
7