Skip to content

Instantly share code, notes, and snippets.

View tacticiankerala's full-sized avatar

Sreenath Nannatt tacticiankerala

View GitHub Profile
vendor_files: {
js: [
'vendor/jquery/jquery.min.js',
'vendor/jquery/jquery.min.map',
'vendor/angular/angular.js',
'vendor/angular-bootstrap/ui-bootstrap-tpls.min.js',
'vendor/placeholders/angular-placeholders-0.0.1-SNAPSHOT.min.js',
'vendor/angular-ui-router/release/angular-ui-router.js',
'vendor/angular-ui-utils/modules/route/route.js',
'vendor/d3/d3.min.js',
@tacticiankerala
tacticiankerala / gist:5549437
Created May 9, 2013 18:22
Singleton class in ruby
require "singleton"
class Configuration
include Singleton
attr_accessor :number
def initialize
self.number = rand
end
end
@tacticiankerala
tacticiankerala / integration_test.rb
Created October 8, 2012 08:07
Ruby Code for running selenium test in firefox through a proxy. We use ZAP as proxy so that we will be notified with possible vulnerabilities exists in our app.
require "selenium-webdriver"
profile = Selenium::WebDriver::Firefox::Profile.new
proxy = Selenium::WebDriver::Proxy.new(:http => "localhost:8080")
profile.proxy = proxy
driver = Selenium::WebDriver.for :firefox , :profile => profile
driver.navigate.to "http://localhost:3000/"
puts driver.title
driver.quit