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
levelup = require("level" ) | |
leveldown = require('leveldown' ) | |
levelgraph = require('levelgraph' ) | |
expect = require('chai' ).expect | |
spawn = require('child_process').spawn | |
class ArticlesGraph | |
constructor: -> | |
@dbPath = "./articlesGraphDB" |
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
{ | |
"title": "Data Validation", | |
"containers": [ | |
{ | |
"title": "Perform Validation on the Server", | |
"id": "4eef2c5f-7108-4ad2-a6b9-e6e84097e9e0", | |
"size": 3 | |
}, | |
{ | |
"title": "Validate All Input", |
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
{ | |
"name": "bsjon_parsing", | |
"version": "1.0.0", | |
"description": "npm json parsing tests", | |
"main": "index.js", | |
"scripts": { | |
"test": "mocha -w --compilers coffee:coffee-script/register ./**/*.*" | |
}, | |
"author": "Dinis Cruz <dinis.cruz@owasp.org> (http://blog.diniscruz.com/)", | |
"license": "ISC", |
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
[ | |
{ "subject": "e7ed2762fc3e" , "predicate": "is an" , "object": "Article" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Guid" , "object": "a330bfdd-9576-40ea-997e-e7ed2762fc3e" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Title" , "object": "All Input Is Validated" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Summary" , "object": "..."}, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Technology", "object": "HTML5" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Phase" , "object": "Implementation" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Type" , "object": "Checklist Item" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "Category" , "object": "Input and Data Validation" }, | |
{ "subject": "e7ed2762fc3e" , "predicate": "View" , "object": "bcea0b7ace25" |
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
var fuzzlist = new List<String>(); | |
Action<string, int> builtList = null; | |
builtList = | |
(prefix, depth)=> | |
{ | |
--depth; | |
for (var letter = 'a'; letter <= 'z'; letter++) | |
{ |
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
chrome.windows.getAll(function(windows) { console.log(windows)} ) | |
chrome.tabs.getAllInWindow(293, function(tabs) { console.log(tabs)}) | |
chrome.tabs.get(364,function(tab) { console.log(tab); _tab = tab}); | |
chrome.tabs.executeScript(364, {code:'console.log("from chrome extension")'},function(response) { console.log(response)}) | |
chrome.tabs.executeScript(364, {code:'alert("from chrome extension")'},function(response) { console.log(response)}) | |
chrome.tabs.executeScript(364, {file:'bower_components/jquery/dist/jquery.min.js'},function(response) { console.log(response)}) | |
var code = "console.log(12)" | |
chrome.tabs.executeScript(364, {code:code}) |
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
require 'fluentnode' | |
wd = require('wd'); | |
browser = wd.remote(); | |
url = "http://localhost:4444/wd/hub/sessions" | |
open_New_Browser_Session = (next)-> | |
"creating new browser session".log() | |
browser.init {browserName:'chrome'},-> | |
browser.get 'file:///Users/diniscruz/_Dev_Tests/node-webkit/my-first-test/index.html',-> |
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
require('nw.gui').Window.open('http://www.google.com', { 'new-instance': true , show:true, toolbar: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
## using watcher | |
require 'fluentnode' | |
fs = require 'fs' | |
project_Folder = atom.project.path | |
coverage_file = project_Folder.path_Combine('coverage/lcov.info') | |
watcher_Src =null | |
watcher_Test =null | |
watcher_Cov =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
console.log('--------------------------') | |
Object.defineProperty global, '__stack', { | |
get: ()-> | |
orig = Error.prepareStackTrace; | |
Error.prepareStackTrace = (_, stack)-> return stack; | |
err = new Error; | |
Error.captureStackTrace(err, arguments.callee); | |
stack = err.stack; | |
Error.prepareStackTrace = orig; |