projects
/
lsp-test.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d8ce533
)
Bump up the number of jobs when building hie in travis
author
Luke Lau
<luke_lau@icloud.com>
Fri, 8 Jun 2018 19:43:48 +0000
(15:43 -0400)
committer
Luke Lau
<luke_lau@icloud.com>
Fri, 8 Jun 2018 19:43:48 +0000
(15:43 -0400)
.travis.yml
patch
|
blob
|
history
test/Test.hs
patch
|
blob
|
history
diff --git
a/.travis.yml
b/.travis.yml
index 22b64e9a342fcbd62e9276021e032f5f0652dcfd..b246a470090b9feb2523c06150cd601fdd78805d 100644
(file)
--- a/
.travis.yml
+++ b/
.travis.yml
@@
-17,7
+17,7
@@
install:
- git clone https://github.com/haskell/haskell-ide-engine.git --recursive
- cd haskell-ide-engine
- git checkout c34c08eeced8173983601e98304258075f3057e1
- git clone https://github.com/haskell/haskell-ide-engine.git --recursive
- cd haskell-ide-engine
- git checkout c34c08eeced8173983601e98304258075f3057e1
- - stack --no-terminal --skip-ghc-check install -j
1
+ - stack --no-terminal --skip-ghc-check install -j
2
- stack exec hoogle generate
- cd ..
- stack exec hoogle generate
- cd ..
diff --git
a/test/Test.hs
b/test/Test.hs
index 401fd9815fd09e81db4f3af8dafeff13ebc2f2ad..13e7ccc5d3066b687c7ca4391a3e6e8af62cbe77 100644
(file)
--- a/
test/Test.hs
+++ b/
test/Test.hs
@@
-1,6
+1,7
@@
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE OverloadedStrings #-}
import Test.Hspec
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE OverloadedStrings #-}
import Test.Hspec
+import Data.Maybe
import Data.Proxy
import Control.Monad.IO.Class
import Control.Lens hiding (List)
import Data.Proxy
import Control.Monad.IO.Class
import Control.Lens hiding (List)
@@
-20,18
+21,19
@@
main = hspec $ do
skipMany loggingNotification
skipMany loggingNotification
-
(NotPublishDiagnostics (NotificationMessage _ TextDocumentPublishDiagnostics (PublishDiagnosticsParams _ (List diags))))
<- notification
+
NotPublishDiagnostics diagsNot
<- notification
- liftIO $ diags
`shouldBe`
[]
+ liftIO $ diags
Not ^. params . diagnostics `shouldBe` List
[]
sendRequest (Proxy :: Proxy DocumentSymbolRequest)
TextDocumentDocumentSymbol
(DocumentSymbolParams docId)
sendRequest (Proxy :: Proxy DocumentSymbolRequest)
TextDocumentDocumentSymbol
(DocumentSymbolParams docId)
-
(RspDocumentSymbols (ResponseMessage _ _ (Just (List symbols)) Nothing))
<- response
+
RspDocumentSymbols rspSymbols
<- response
liftIO $ do
liftIO $ do
- let mainSymbol = head symbols
+ let (List symbols) = fromJust (rspSymbols ^. result)
+ mainSymbol = head symbols
mainSymbol ^. name `shouldBe` "main"
mainSymbol ^. kind `shouldBe` SkFunction
mainSymbol ^. location . range `shouldBe` Range (Position 3 0) (Position 3 4)
mainSymbol ^. name `shouldBe` "main"
mainSymbol ^. kind `shouldBe` SkFunction
mainSymbol ^. location . range `shouldBe` Range (Position 3 0) (Position 3 4)