This file contains hidden or 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
{ | |
"Username": { | |
"de-DE": "Benutzername", | |
"en-US": "Username" | |
}, | |
"Language": { | |
"de-DE": "Sprache", | |
"tr-TR": "Dil" | |
} | |
} |
This file contains hidden or 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
add-type @" | |
using System; | |
using System.Linq; | |
public class A { | |
public A() { Age = 40; Name = "DerAlbert"; Type = "Original"; } | |
public int Age { get; set; } | |
public string Name { get; set; } | |
public string Type { get; set; } | |
public A With(object o) { |
This file contains hidden or 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
/* | |
There's this very pleasant and fulfilling moment in every developer's life | |
when it comes to comparing values. Especially testing for equality sometimes | |
is full of emotions. Sometimes, you don't want to "just simply" check if | |
values are equal. You want more. You want to express enthusiasm! Emotion! | |
Yeah, right, equals! You want | |
___ __ __ ____ _____ ___ _ _ _ _ ____ | |
/ _ \| \/ |/ ___| | ____/ _ \| | | | / \ | | / ___| | |
| | | | |\/| | | _ | _|| | | | | | |/ _ \ | | \___ \ |
This file contains hidden or 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
/* Question: | |
What do you expect from assertion below? Fail or Pass? | |
*/ | |
List<string> aList = new List<string> { "any" }; | |
List<string> anEmptyList = new List<string>(); | |
aList.ShouldContain(anEmptyList); // this currently passes! |
This file contains hidden or 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
class Foo | |
def bar(n) | |
return gin n | |
end | |
def gin(n) | |
return n+1 | |
end | |
end | |
This file contains hidden or 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
SCRIPT=$(realname -f $0) | |
SCRIPTPATH=`dirname $SCRIPT` |
This file contains hidden or 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 IEnumerable<Answer> GetAll() | |
{ | |
List<Answer> answers = GetAnswers(); | |
return answers; | |
} |
This file contains hidden or 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
(tf localversions . /recursive|?{$_ -match ".*;C.*"}|%{$_ -replace ".*;C",""}|group|%{$_.name}|sort -desc)[0] |
This file contains hidden or 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
using Machine.Fakes; | |
using Machine.Specifications; | |
namespace MFakesTest { | |
public class when_using_mfakes_via_nuget_package_manager : WithSubject<Anything> { | |
private It should_run_fine | |
= () => Subject.True.ShouldBeTrue(); | |
Because of_using_mfakes | |
= () => Subject.True = true; |
This file contains hidden or 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 void TriplePlus() | |
{ | |
int coffee = 0; | |
// constant linear growth by 1 on every access until reset | |
IEnumerable<int> drink = coffee+++; | |
var enjoy = | |
from slurp in drink | |
where slurp <= 100 |