nodejs.md - cccnqu/se106a GitHub Wiki
- 以登入功能為例 -- userManager.login(id, password)
- 使用者進入登入畫面
- 使用者輸入帳號密碼
- UI 將帳號密碼傳給《使用者管理員》
- 《使用者管理員》檢查帳號密碼是否正確
- 《使用者管理員》傳回檢查結果
- 檢查成功,UI 導入系統進入畫面,若失敗 (帳號密碼不對),則提示重新輸入。(三次錯誤則拒絕登入)
- node-inspector : https://github.com/node-inspector/node-inspector
- require('debug')() -- https://www.npmjs.com/package/debug
- visual studio code -- debug
- https://macacajs.com/ -- 用户端软件的测试解决方案
- Test
- Mocha : https://mochajs.org/
- TDD, BDD : http://chaijs.com/
- AVA : https://github.com/avajs/ava
- Jasmine : https://github.com/jasmine/jasmine
- Spectron : https://github.com/electron/spectron
- supertest : 可測試 server 的回傳內容是否正確
- cheerio : 可用 jquery style 的方式處理字串
- PhantomJS : http://phantomjs.org/
- selenium : http://www.seleniumhq.org/
- Puppeteer : https://github.com/GoogleChrome/puppeteer
- Headless Chrome : https://developers.google.com/web/updates/2017/04/headless-chrome
- 優點:使用 async/await
https://github.com/mikolalysenko/ndarray-experiments/blob/master/experiment.js
Easy profiling for Node.js Applications
Node.js 性能调优之CPU篇(一)——perf+火焰图
Performance testing our NodeJS API
以下參數目前似乎只有 linux 能用!
$ node --perf_basic_prof <file>
-
https://github.com/niteshpsit/test-generator
- Test Cases Generator For RESTful APIS or node apis , token or cookies based
- How can I dynamically generate test cases in javascript/node?
- Jenkins : https://jenkins.io/
- TravisCI : https://travis-ci.org/
Gulp : concat, minify, uglify, sass=>css, Grunt Webpack Make
-
https://github.com/remy/nodemon
- Monitor for any changes in your node.js application and automatically restart the server - perfect for development
-
https://github.com/mikeal/watch
- watch -- Utilities for watching file trees in node.js