I hereby claim:
- I am MathieuAuclair on github.
- I am mathieuauclair (https://keybase.io/mathieuauclair) on keybase.
- I have a public key whose fingerprint is EEB0 97F9 612C C8E1 A9BB D628 D363 9532 E6E2 3FDD
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
isAscii("é") //false | |
function isAscii(str) { | |
for (var i = 0, strLen = str.length; i < strLen; ++i) { | |
if (str.charCodeAt(i) > 125) return false; | |
} | |
return true; | |
} |
Note that this is not a regular use case. Reflexion should be avoided, and your code structure should always be adapted for tests. Perhaps if you don't have the choice, private properties can still be tested!
let's see an example here with a selfish encapsulated class
public class SelfishClass
{
private string[] Goodies {get; set;}
RegexDictionary = new Dictionary<string, Regex> | |
{ | |
{"tests", new Regex("@tests\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"fixed", new Regex("@fixed\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"review", new Regex("@review\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"tested", new Regex("@tested\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"submitassistant", new Regex("@submitassistant\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"releasenotes", new Regex("@releasenotes\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"change", new Regex("@change\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"waswarned", new Regex("@waswarned\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, |
// Upgrade NOTE: replaced 'mul(UNITY_MATRIX_MVP,*)' with 'UnityObjectToClipPos(*)' | |
Shader "Unlit/FlashingMaker" | |
{ | |
Properties | |
{ | |
_MainTex ("Base (RGB)", 2D) = "white" {} | |
_Color ("Color (RGBA)", Color) = (1, 1, 1, 1) // add _Color property | |
} |