如何在開發的過程中加入測試。
- Model
- Repository
- Controller
- Auth
FR.onload = (e) { | |
let af = e.target.result | |
, view = new DataView(af) | |
, first4Byte = view.getUint32(0, false); | |
let hexValue = Number(first4Byte).toString(16); | |
switch (hexValue) { | |
case 'FFD8FFE0': | |
case 'FFD8FFE1': |
type FilterOperator = 'AND' | 'OR'; | |
type FiltersBy<T> = { | |
[K in keyof T]?: (value: T[K]) => boolean; | |
}; | |
/** | |
* Factory function that creates a specialized function to filter | |
* arrays, by validating all filters (AND operator), | |
* or validating just one of the filters (OR operator). | |
* @param operator Method to validate all filters: AND, OR |
// dashboard component | |
var dashboard = Vue.extend({ | |
template: '<p>Hello from dashboard</p>' | |
}) | |
// user management component | |
var user = Vue.extend({ | |
template: '<p>Hello from user management page</p>' | |
}) |
https://github.com/gslin/coscup2015-mysql-hands-on | |
開場 | |
# Transaction | |
## 原子不可分割性 | |
要碼全部成功不然就全部失敗 - 銀行轉帳 (林益世 v.s. 陳啟祥) | |
持久性 (D) |
<?php | |
use Illuminate\Foundation\Testing\DatabaseMigrations; | |
use Illuminate\Foundation\Testing\DatabaseTransactions; | |
use Illuminate\Support\Facades\Auth; | |
class ExampleTest extends TestCase | |
{ | |
/** | |
* DatabaseTransactions :在測試其間對資料庫的所有操作會在測試完成後被滾回 |
{ | |
"env": { | |
"browser": true, | |
"node": true, | |
"es6": true | |
}, | |
"plugins": ["react"], | |
"ecmaFeatures": { |
#Laravel 5 Simple ACL manager
Protect your routes with user roles. Simply add a 'role_id' to the User model, install the roles table and seed if you need some example roles to get going.
If the user has a 'Root' role, then they can perform any actions.
Simply copy the files across into the appropriate directories, and register the middleware in App\Http\Kernel.php
Disclaimer: This is an unofficial post by a random person from the community. I am not an official representative of io.js. Want to ask a question? open an issue on the node-forward
discussions repo
Copyright (C) 2016 Donnie Ray Jones | |
Permission is hereby granted, free of charge, to any person obtaining a | |
copy of this software and associated documentation files (the | |
"Software"), to deal in the Software without restriction, including | |
without limitation the rights to use, copy, modify, merge, publish, | |
distribute, sublicense, and/or sell copies of the Software, and to | |
permit persons to whom the Software is furnished to do so, subject to | |
the following conditions: |