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
private static void MemoryStreamTest() | |
{ | |
string localFilePath = @"c:\tmp"; | |
try | |
{ | |
using (MemoryStream memoryStream = new MemoryStream()) | |
{ | |
for (int i = 0; i< 256;i++) | |
{ |
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
<ItemGroup> | |
<DataFiles Include="$(ProjectDir)Data\**\*.*" /> | |
</ItemGroup> | |
<Target Name="PostBuild" AfterTargets="PostBuildEvent"> | |
<Copy SourceFiles="@(DataFiles)" DestinationFiles="@(DataFiles->'$(TargetDir)Data\%(RecursiveDir)%(Filename)%(Extension)')" SkipUnchangedFiles="true" /> | |
</Target> | |
<Target Name="AddPayloadsFolder" AfterTargets="Publish"> | |
<Copy SourceFiles="@(DataFiles)" DestinationFiles="@(DataFiles->'$(PublishDir)Data\%(RecursiveDir)%(Filename)%(Extension)')" SkipUnchangedFiles="true" /> |
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
import org.openqa.selenium.WebDriver; | |
import org.openqa.selenium.firefox.FirefoxDriver; | |
import org.openqa.selenium.firefox.FirefoxProfile; | |
/** | |
* Created by Amol Chavan on 9/19/2016. | |
*/ | |
public class PrivateBrowsing { | |
public static void main(String args[]){ |
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
import static com.jayway.jsonpath.JsonPath.parse | |
def json = '''{"quote": { | |
"id": 12345, | |
"am ount": 100, | |
"links": [ | |
{ | |
"rel": "self", | |
"href": "http://localhost:8080/quote/777" | |
}, |
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
// http://stackoverflow.com/questions/1219860/javascript-jquery-html-encoding?answertab=votes#tab-top | |
function htmlEncode(value){ | |
"use strict"; | |
//create a in-memory div, set it's inner text(which jQuery automatically encodes) | |
//then grab the encoded contents back out. The div never exists on the page. | |
return $('<div/>').text(value).html(); | |
} | |
function htmlDecode(value){ | |
"use strict"; |