describe "manual session validation" $
it "passes a test" $
runSession "test/recordings/renamePass" $ do
- docItem <- getDocItem "Desktop/simple.hs" "haskell"
- docId <- TextDocumentIdentifier <$> getDocUri "Desktop/simple.hs"
-
- sendNotification TextDocumentDidOpen (DidOpenTextDocumentParams docItem)
+ doc <- openDoc "Desktop/simple.hs" "haskell"
skipMany loggingNotification
sendRequest (Proxy :: Proxy DocumentSymbolRequest)
TextDocumentDocumentSymbol
- (DocumentSymbolParams docId)
+ (DocumentSymbolParams doc)
RspDocumentSymbols rspSymbols <- response
mainSymbol ^. location . range `shouldBe` Range (Position 3 0) (Position 3 4)
mainSymbol ^. containerName `shouldBe` Nothing
- describe "replay session" $
+ describe "replay session" $ do
it "passes a test" $
replaySession "test/recordings/renamePass" `shouldReturn` True
+ it "fails a test" $
+ replaySession "test/recordings/renameFail" `shouldReturn` False
\ No newline at end of file