[ 
https://issues.apache.org/jira/browse/CB-13945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16383625#comment-16383625
 ] 

Jan Piotrowski (Sujan) commented on CB-13945:
---------------------------------------------

[~dblotsky], do you know any about that?

> `npm test` still relevant?
> --------------------------
>
>                 Key: CB-13945
>                 URL: https://issues.apache.org/jira/browse/CB-13945
>             Project: Apache Cordova
>          Issue Type: Task
>          Components: cordova-docs
>            Reporter: Jan Piotrowski (Sujan)
>            Priority: Major
>
> There are some tests in cordova-docs which can be run with `npm test`, 
> described here: 
> https://github.com/apache/cordova-docs/blob/master/doc/testing-the-website.md 
> {code}
> C:\Projects\Cordova\cordova-docs (janpio-random_docs_stuff -> origin) 
> (cordova-website@0.0.1)
> λ npm test
> > cordova-website@0.0.1 test C:\Projects\Cordova\cordova-docs
> > npm run eslint && npm run mocha
> > cordova-website@0.0.1 eslint C:\Projects\Cordova\cordova-docs
> > eslint tools/lib tools/spec
> > cordova-website@0.0.1 mocha C:\Projects\Cordova\cordova-docs
> > mocha --recursive tools/spec
> (node:11372) [DEP0006] DeprecationWarning: child_process: options.customFds 
> option is deprecated. Use options.stdio instead.
>   AddTitle
>     √ should set the title
>     √ should skip files with no source title
>     √ should skip files with no target title
>   Prettify
>     √ should find some code blocks
>     √ should add the prettyprint class to each code block
>   TableOfContents
>     √ should find the table of content values
>     √ should find all <h1> elements
>     √ should find all <h2> elements
>     √ should ignore whitespace in the target name
>     √ should create a HTML select element
>     √ should skip files with no source title
>     √ should skip files with no target title
>   UpdateIndex
>     √ should skip all files but index.md.html
>     √ should rename the title
>     √ should rename the file
>   UpdateKeywordIndex
>     √ should skip all files but _index.html
>     √ should rename the title
>     √ should rename the h1 (66ms)
>     √ should remove the <hr/>
>     √ should update references from index.md.html to index.html
>   YamlFrontMatter
>     √ should skip files with no YAML Front Matter
>     √ should parse files with YAML Front Matter
>   FileHelpers
>     - should have a default input directory that exists
>   22 passing (901ms)
>   1 pending
> {code}
> If you follow the trail, this seems to run the tests in `tools/spec/cordova`. 
> Looking into the actual spec files, it seems to test functionality in these 
> files:
> - /lib/cordova/post/addtitle
> - /lib/cordova/post/prettify
> - /lib/cordova/post/tableofcontents
> - /lib/cordova/post/updateindex
> - /lib/cordova/post/updatekeywordindex
> - /lib/cordova/pre/yamlfrontmatter
> Is the code being tested here actually still relevant for the current state 
> of the docs?



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org
For additional commands, e-mail: issues-h...@cordova.apache.org

Reply via email to