Skip to content

Commit

Permalink
Coverage update (#155)
Browse files Browse the repository at this point in the history
* Also upload coverage info next to the API. Try to upload more data to coveralls.

* deploy script fix, coveralls reporting back to normal

* Create an index.html at the deployed documentation.

* Updated documentation for AST.References
  • Loading branch information
nboldi committed Nov 2, 2016
1 parent 67dc577 commit b541c02
Show file tree
Hide file tree
Showing 4 changed files with 90 additions and 54 deletions.
9 changes: 9 additions & 0 deletions branch-info-index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<!DOCTYPE html>
<html>
<body>

<h2><a href="api/index.html">Generated API documentation</a></h2>
<h2><a href="coverage/hpc_index.html">Test coverage report</a></h2>

</body>
</html>
14 changes: 12 additions & 2 deletions deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,22 @@ ssh-add deploykey
git clone git@github.com:haskell-tools/haskell-tools.github.io out

# Clean out existing contents
rm -rf out/$TRAVIS_BRANCH/api/**/* || exit 0
rm -rf out/$TRAVIS_BRANCH/api/**
rm -rf out/$TRAVIS_BRANCH/coverage/**

# Copy generated haddock documentation

mkdir -p out/$TRAVIS_BRANCH/api
cp -r .stack-work/install/x86_64-linux/nightly-2016-09-10/8.0.1/doc/* out/$TRAVIS_BRANCH/api
cp -r .stack-work/install/x86_64-linux/lts-7.7/8.0.1/doc/* out/$TRAVIS_BRANCH/api

# Copy the test coverage report

mkdir -p out/$TRAVIS_BRANCH/coverage
cp -r .stack-work/install/x86_64-linux/lts-7.7/8.0.1/hpc/combined/all/* out/$TRAVIS_BRANCH/coverage

# Create an index page
cp branch-info-index.html out/$TRAVIS_BRANCH/index.html

cd out

git config user.name "Travis CI"
Expand Down
120 changes: 68 additions & 52 deletions src/ast/Language/Haskell/Tools/AST/References.hs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{-# LANGUAGE FlexibleContexts, TemplateHaskell #-}
-- Generated references for handling the custom AST
-- | Generated references for AST elements.
module Language.Haskell.Tools.AST.References where

import Control.Reference hiding (element)
Expand All @@ -18,7 +18,7 @@ import Language.Haskell.Tools.AST.Representation.Literals
import Language.Haskell.Tools.AST.Representation.Names
import Language.Haskell.Tools.AST.Ann

-- Modules
-- * Modules
$(toASTReferences (makeReferences ''UModule))
$(toASTReferences (makeReferences ''UModuleHead))
$(toASTReferences (makeReferences ''UExportSpecs))
Expand All @@ -33,16 +33,29 @@ $(toASTReferences (makeReferences ''UImportSource))
$(toASTReferences (makeReferences ''UImportSafe))
$(toASTReferences (makeReferences ''UTypeNamespace))
$(toASTReferences (makeReferences ''UImportRenaming))
$(toASTReferences (makeReferences ''UModuleName))
$(toASTReferences (makeReferences ''ULanguageExtension))
$(toASTReferences (makeReferences ''TypeKeyword))

-- Declarations
-- * Declarations
$(toASTReferences (makeReferences ''UDecl))
$(toASTReferences (makeReferences ''UClassBody))
$(toASTReferences (makeReferences ''UClassElement))
$(toASTReferences (makeReferences ''UDeclHead))
$(toASTReferences (makeReferences ''UInstBody))
$(toASTReferences (makeReferences ''UInstBodyDecl))
$(toASTReferences (makeReferences ''UTypeFamily))
$(toASTReferences (makeReferences ''UTypeFamilySpec))
$(toASTReferences (makeReferences ''UInjectivityAnn))
$(toASTReferences (makeReferences ''UDataOrNewtypeKeyword))
$(toASTReferences (makeReferences ''UGadtConDecl))
$(toASTReferences (makeReferences ''UGadtConType))
$(toASTReferences (makeReferences ''UPatternSynonym))
$(toASTReferences (makeReferences ''UPatSynRhs))
$(toASTReferences (makeReferences ''UPatSynLhs))
$(toASTReferences (makeReferences ''UPatSynWhere))
$(toASTReferences (makeReferences ''UPatternTypeSignature))
$(toASTReferences (makeReferences ''URole))
$(toASTReferences (makeReferences ''UFunDeps))
$(toASTReferences (makeReferences ''UFunDep))
$(toASTReferences (makeReferences ''UConDecl))
Expand All @@ -51,75 +64,78 @@ $(toASTReferences (makeReferences ''UDeriving))
$(toASTReferences (makeReferences ''UInstanceRule))
$(toASTReferences (makeReferences ''UInstanceHead))
$(toASTReferences (makeReferences ''UTypeEqn))
$(toASTReferences (makeReferences ''URule))
$(toASTReferences (makeReferences ''UOverlapPragma))
$(toASTReferences (makeReferences ''UCallConv))
$(toASTReferences (makeReferences ''USafety))
$(toASTReferences (makeReferences ''UPhaseControl))
$(toASTReferences (makeReferences ''PhaseNumber))
$(toASTReferences (makeReferences ''PhaseInvert))
$(toASTReferences (makeReferences ''UTopLevelPragma))
$(toASTReferences (makeReferences ''UAnnotationSubject))
$(toASTReferences (makeReferences ''UMinimalFormula))
$(toASTReferences (makeReferences ''USourceRange))
$(toASTReferences (makeReferences ''Number))


-- * Binds
$(toASTReferences (makeReferences ''UMatch))
$(toASTReferences (makeReferences ''URhs))
$(toASTReferences (makeReferences ''UGuardedRhs))
$(toASTReferences (makeReferences ''URhsGuard))
$(toASTReferences (makeReferences ''ULocalBind))
$(toASTReferences (makeReferences ''ULocalBinds))
$(toASTReferences (makeReferences ''UFixitySignature))
$(toASTReferences (makeReferences ''Assoc))
$(toASTReferences (makeReferences ''Precedence))
$(toASTReferences (makeReferences ''UTypeSignature))
$(toASTReferences (makeReferences ''UMatchLhs))

-- * Kinds
$(toASTReferences (makeReferences ''UKindConstraint))

-- * Types
$(toASTReferences (makeReferences ''UValueBind))
$(toASTReferences (makeReferences ''UTyVar))
$(toASTReferences (makeReferences ''UType))
$(toASTReferences (makeReferences ''UKind))
$(toASTReferences (makeReferences ''UContext))
$(toASTReferences (makeReferences ''UAssertion))

-- * Expressions
$(toASTReferences (makeReferences ''UExpr))
$(toASTReferences (makeReferences ''UAlt'))
$(toASTReferences (makeReferences ''UFieldUpdate))
$(toASTReferences (makeReferences ''UTupSecElem))
$(toASTReferences (makeReferences ''UExprPragma))
$(toASTReferences (makeReferences ''UCaseRhs'))
$(toASTReferences (makeReferences ''UGuardedCaseRhs'))
$(toASTReferences (makeReferences ''UArrowAppl))

-- * Statements
$(toASTReferences (makeReferences ''UStmt'))
$(toASTReferences (makeReferences ''UCompStmt))
$(toASTReferences (makeReferences ''UValueBind))
$(toASTReferences (makeReferences ''UListCompBody))
$(toASTReferences (makeReferences ''UDoKind))

-- * Patterns
$(toASTReferences (makeReferences ''UPattern))
$(toASTReferences (makeReferences ''UPatternField))

-- * Template Haskell
$(toASTReferences (makeReferences ''USplice))
$(toASTReferences (makeReferences ''UQuasiQuote))
$(toASTReferences (makeReferences ''QQString))
$(toASTReferences (makeReferences ''UMatch))
$(toASTReferences (makeReferences ''UAlt'))
$(toASTReferences (makeReferences ''URhs))
$(toASTReferences (makeReferences ''UGuardedRhs))
$(toASTReferences (makeReferences ''UFieldUpdate))
$(toASTReferences (makeReferences ''UBracket))
$(toASTReferences (makeReferences ''UTopLevelPragma))
$(toASTReferences (makeReferences ''URule))
$(toASTReferences (makeReferences ''UAnnotationSubject))
$(toASTReferences (makeReferences ''UMinimalFormula))
$(toASTReferences (makeReferences ''UExprPragma))
$(toASTReferences (makeReferences ''USourceRange))
$(toASTReferences (makeReferences ''Number))
$(toASTReferences (makeReferences ''UQuasiQuote))
$(toASTReferences (makeReferences ''URhsGuard))
$(toASTReferences (makeReferences ''ULocalBind))
$(toASTReferences (makeReferences ''ULocalBinds))
$(toASTReferences (makeReferences ''UFixitySignature))
$(toASTReferences (makeReferences ''UTypeSignature))
$(toASTReferences (makeReferences ''UListCompBody))
$(toASTReferences (makeReferences ''UTupSecElem))
$(toASTReferences (makeReferences ''UTypeFamily))
$(toASTReferences (makeReferences ''UTypeFamilySpec))
$(toASTReferences (makeReferences ''UInjectivityAnn))
$(toASTReferences (makeReferences ''UCaseRhs'))
$(toASTReferences (makeReferences ''UGuardedCaseRhs'))
$(toASTReferences (makeReferences ''UPatternSynonym))
$(toASTReferences (makeReferences ''UPatSynRhs))
$(toASTReferences (makeReferences ''UPatSynLhs))
$(toASTReferences (makeReferences ''UPatSynWhere))
$(toASTReferences (makeReferences ''UPatternTypeSignature))
$(toASTReferences (makeReferences ''URole))
$(toASTReferences (makeReferences ''ULanguageExtension))
$(toASTReferences (makeReferences ''UMatchLhs))

-- ULiteral
-- * Literals
$(toASTReferences (makeReferences ''ULiteral))
$(toASTReferences (makeReferences ''UPromoted))

-- Base
-- * Names
$(toASTReferences (makeReferences ''UOperator))
$(toASTReferences (makeReferences ''UName))
$(toASTReferences (makeReferences ''UQualifiedName))
$(toASTReferences (makeReferences ''UModuleName))
$(toASTReferences (makeReferences ''UNamePart))
$(toASTReferences (makeReferences ''UStringNode))
$(toASTReferences (makeReferences ''UDataOrNewtypeKeyword))
$(toASTReferences (makeReferences ''UDoKind))
$(toASTReferences (makeReferences ''TypeKeyword))
$(toASTReferences (makeReferences ''UOverlapPragma))
$(toASTReferences (makeReferences ''UCallConv))
$(toASTReferences (makeReferences ''UArrowAppl))
$(toASTReferences (makeReferences ''USafety))
$(toASTReferences (makeReferences ''Assoc))
$(toASTReferences (makeReferences ''Precedence))
$(toASTReferences (makeReferences ''UPhaseControl))
$(toASTReferences (makeReferences ''PhaseNumber))
$(toASTReferences (makeReferences ''PhaseInvert))

1 change: 1 addition & 0 deletions src/refactor/haskell-tools-refactor.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ test-suite haskell-tools-test
, references >=0.3.2 && <1.0
, split >=0.2 && <1.0
, time >=1.5 && <2.0
, old-time >=1.1 && <2.0
, template-haskell >=2.0 && <3.0
, Cabal >=1.24 && <2.0
, polyparse >=1.12 && <2.0
Expand Down

0 comments on commit b541c02

Please sign in to comment.