如何在開發的過程中加入測試。
- Model
- Repository
- Controller
- Auth
var httpStatusCodes = { | |
// 1xx Informational | |
// Request received, continuing process.[2] | |
// This class of status code indicates a provisional response, consisting only of the Status-Line and optional headers, and is terminated by an empty line. Since HTTP/1.0 did not define any 1xx status codes, servers must not send a 1xx response to an HTTP/1.0 client except under experimental conditions. | |
'100': 'Continue', //This means that the server has received the request headers, and that the client should proceed to send the request body (in the case of a request for which a body needs to be sent; for example, a POST request). If the request body is large, sending it to a server when a request has already been rejected based upon inappropriate headers is inefficient. To have a server check if the request could be accepted based on the request's headers alone, a client must send Expect: 100-continue as a header in its initial request[2] and check if a 100 Continue status code is received in response be |
這篇文章旨在作為快速參考與展示。要更多完整的資訊,請見 John Gruber 原本的規格與 Github 偏好的 Markdown(Github-flavored Markdown,簡寫為GFM)資訊頁。
如果你正在找 Markdown Here 的小抄(Cheatsheet),這裡也有一篇。你也可以看看更多 Markdown 的工具。
譯註:可以參考這份中文版文件,有更詳盡的 Markdown 語法說明;如果需要可以練習的線上編輯器,可以試試看HackMD。
// Trie.js - super simple JS implementation | |
// https://en.wikipedia.org/wiki/Trie | |
// ----------------------------------------- | |
// we start with the TrieNode | |
function TrieNode(key) { | |
// the "key" value will be the character in sequence | |
this.key = key; | |
scriptencoding utf-8 | |
" To install nvim on ubuntu: | |
" sudo apt-get install software-properties-common | |
" sudo add-apt-repository ppa:neovim-ppa/unstable | |
" sudo apt-get update | |
" sudo apt-get install neovim | |
" sudo apt-get install python-dev python-pip python3-dev python3-pip | |
" sudo update-alternatives --install /usr/bin/vi vi /usr/bin/nvim 60 | |
" sudo update-alternatives --config vi |
<?php | |
// This can be found in the Symfony\Component\HttpFoundation\Response class | |
const HTTP_CONTINUE = 100; | |
const HTTP_SWITCHING_PROTOCOLS = 101; | |
const HTTP_PROCESSING = 102; // RFC2518 | |
const HTTP_OK = 200; | |
const HTTP_CREATED = 201; | |
const HTTP_ACCEPTED = 202; |
" Specify a directory for plugins | |
call plug#begin('~/.vim/plugged') | |
Plug 'neoclide/coc.nvim', {'branch': 'release'} | |
Plug 'scrooloose/nerdtree' | |
"Plug 'tsony-tsonev/nerdtree-git-plugin' | |
Plug 'Xuyuanp/nerdtree-git-plugin' | |
Plug 'tiagofumo/vim-nerdtree-syntax-highlight' | |
Plug 'ryanoasis/vim-devicons' | |
Plug 'airblade/vim-gitgutter' |