- Install Codeception via Composer.
composer require "codeception/codeception:@stable"
- Create the bootstrap in the app directory.
codecept bootstrap app
- Set the PhpBrowser url config in app/tests/acceptance.suite.yml.
- Move the codeception.yml file to the root directory.
mv app/codeception.yml codeception.yml
- Adjust the paths in codeception.yml to reference app/tests rather than tests.
- Move TestCase.php to the unit tests directory.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Usage: | |
var myLatLng = new google.maps.LatLng(point.lat, point.lng); | |
var myMarker = new CustomMarker(myLatLng,map); | |
Implementation (mostly from googles example): | |
function CustomMarker(latlng, map) { | |
this.latlng_ = latlng; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function my_array_diff($a, $b) | |
{ | |
$map = $out = array(); | |
foreach ($a as $val) | |
$map[$val] = 1; | |
foreach ($b as $val) | |
if (isset($map[$val])) | |
$map[$val] = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class ClickToSelectEditText <T> extends AppCompatEditText { | |
CharSequence mHint; | |
OnItemSelectedListener<T> onItemSelectedListener; | |
ListAdapter mSpinnerAdapter; | |
public ClickToSelectEditText(Context context) { | |
super(context); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
Event::listen('illuminate.query', function($query, $bindings, $time) { | |
static $count; | |
if(App::make('env') === 'local') | |
{ | |
$logFile = __DIR__.'/../storage/logs/queries'; | |
ob_start(); | |
var_dump($bindings, $query); | |
$str = ob_get_clean(); | |
if($count === null) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vue.component('child', { | |
ready(){ | |
// send flash message | |
this.$root.$broadcast('flashMessage',{ | |
text: 'Better check yourself, you\'re not looking too good.', | |
type: 'warning',//optional | |
important: false,//optional | |
timeout: 5000//optional | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Quick cp from http://sekati.com/etc/install-nodejs-on-debian-squeeze | |
# | |
#Needed to install TileMill from MapBox | |
# | |
#Installs node.js which has npm bundled | |
# | |
#Build Dependencies | |
sudo apt-get update && apt-get install git-core curl build-essential openssl libssl-dev |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Database\Schema; | |
use Illuminate\Database\Schema\Blueprint as ParentBlueprint; | |
use Illuminate\Support\Facades\DB; | |
/** | |
* Class Blueprint | |
* |
OlderNewer