Real unit test (isolation, no children render)
Calls:
- constructor
- render
#!/bin/bash | |
error_exit() | |
{ | |
echo "$1" 1>&2 | |
exit 1 | |
} | |
CODEBUILD_PROJECT_NAME=$1 |
# set the base image to Debian | |
# https://hub.docker.com/_/debian/ | |
FROM debian:latest | |
# replace shell with bash so we can source files | |
RUN rm /bin/sh && ln -s /bin/bash /bin/sh | |
# update the repository sources list | |
# and install dependencies | |
RUN apt-get update \ |
function asyncFunc(e) { | |
return new Promise((resolve, reject) => { | |
setTimeout(() => resolve(e), e * 1000); | |
}); | |
} | |
const arr = [1, 2, 3]; | |
let final = []; | |
function workMyCollection(arr) { |
// https://gist.github.com/edoardocavazza/47246856759f2273e48b | |
(function () { | |
if (typeof Object.setPrototypeOf === 'undefined' && typeof Object.getOwnPropertyNames === 'function') { | |
var _exclude = ['length', 'name', 'arguments', 'caller', 'prototype']; | |
function bindFunction(ctx, fn) { | |
return function() { | |
return fn.apply(this, arguments); | |
} | |
} |
var AWS = require('aws-sdk'); | |
var http = require('http'); | |
var httpProxy = require('http-proxy'); | |
var express = require('express'); | |
var bodyParser = require('body-parser'); | |
var stream = require('stream'); | |
if (process.argv.length != 3) { | |
console.error('usage: aws-es-proxy <my-cluster-endpoint>'); | |
process.exit(1); |
Disable vim automatic visual mode on mouse select | |
issue: :set mouse-=a | |
add to ~/.vimrc: set mouse-=a | |
my ~/.vimrc for preserving global defaults and only changing one option: | |
source $VIMRUNTIME/defaults.vim | |
set mouse-=a |
<?php | |
class soapclientd extends soapclient | |
{ | |
public $action = false; | |
public function __construct($wsdl, $options = array()) | |
{ | |
parent::__construct($wsdl, $options); | |
} |