Skip to content

Instantly share code, notes, and snippets.

View evanniedojadlo's full-sized avatar
💭
Stone in Focus 🗿

Evan Niedojadło evanniedojadlo

💭
Stone in Focus 🗿
View GitHub Profile
@evanniedojadlo
evanniedojadlo / Codecademy Bug
Created May 18, 2014 07:25
JS function that is causing Codecademy to output three different values
//This function is returning three different outputs within Codecademy
var orangeCost = function(price) {
console.log(price * 5);
}
orangeCost(2);
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script>
@evanniedojadlo
evanniedojadlo / Multi-Image Uploader
Created September 5, 2014 19:48
Quick image uploader (no styles added)
<html>
<head>
<title>Test Image Uploader</title>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script id="angularScript" src="//ajax.googleapis.com/ajax/libs/angular"></script>
<script>
$(document).ready(init);
function init(){
console.log('Document has been loaded');
@evanniedojadlo
evanniedojadlo / gist:937c9a0e743730392953
Created June 22, 2015 06:13
Firefox quit unexpectedly - Problem Report for Firefox
Process: firefox-bin [88202]
Path: /Applications/Firefox.app/Contents/MacOS/firefox-bin
Identifier: org.mozilla.firefox
Version: 38.0.5 (3815.5.25)
Code Type: X86-64 (Native)
Parent Process: ruby [88201]
Responsible: iTerm [12157]
User ID: 501
Date/Time: 2015-06-22 01:09:52.218 -0500
@evanniedojadlo
evanniedojadlo / base.rb
Created June 22, 2015 06:16
Basic Test which is run against Firefox
#base is used for building out the tests structure
require 'selenium-webdriver'
class Base
def initialize(driver)
@driver = driver
end
@evanniedojadlo
evanniedojadlo / gist:dd37c1ca0316410fa04c
Created July 8, 2015 22:19
Gallio - Runtime log errors that we are returning
Host started at 7/8/2015 4:55:09 PM.
Running under CLR v4.0.30319 runtime.
Host stopped at 7/8/2015 4:55:11 PM.
Host process exited with code: 0
A fatal exception occurred while exploring tests. Possible causes include invalid test runner parameters.
Gallio.Model.ModelException: An exception occurred while invoking a test driver. ---> System.Runtime.Serialization.SerializationException: Type 'Microsoft.Cci.Pdb.PdbDebugException' in Assembly 'Gallio, Version=3.4.0.0, Culture=neutral, PublicKeyToken=eb9cfa67ee6ab36e' is not marked as serializable.
HResult: -2146233076
Server stack trace:
at System.Runtime.Serialization.Formatters.Binary.WriteObjectInfo.InitSerialize(Object obj, ISurrogateSelector surrogateSelector, StreamingContext context, SerObjectInfoInit serObjectInfoInit, IFormatterConverter converter, ObjectWriter objectWriter, SerializationBinder binder)
@evanniedojadlo
evanniedojadlo / ide_export.rb
Created July 17, 2013 03:48
A brief example of how to convert exported Selenium IDE tests into runnable tests with the Sauce platform.
# Exported as Test::Unit from Selenium IDE
require "selenium-webdriver"
gem "test-unit"
require "test/unit"
class Example2 < Test::Unit::TestCase
def setup
@driver = Selenium::WebDriver.for :firefox
@evanniedojadlo
evanniedojadlo / gist:8293968
Last active January 2, 2016 10:59
Error I am returning when attempting a rake db:seed or a rake db:reset
Evans-MacBook-Air:wikiful RAI$ rake db:reset
-- enable_extension("plpgsql")
-> 0.0452s
-- create_table("article_categories", {:force=>true})
-> 0.0115s
-- create_table("articles", {:force=>true})
-> 0.0083s
-- create_table("categories", {:force=>true})
-> 0.0083s
-- initialize_schema_migrations_table()
@evanniedojadlo
evanniedojadlo / gist:8295360
Created January 7, 2014 06:20
Message returned after I performed a rake db:drop, rake db:create, rake db:migrate, and the rake db:seed
Evans-MacBook-Air:wikiful RAI$ rake db:seed
[deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message.
@evanniedojadlo
evanniedojadlo / gist:1b1a3f93cc09a4ba647df3712172a01d
Created May 12, 2016 01:47
Error we are seeing when attempting to run sauce_ios_web.rb
Applitools_Test ruby sauce_ios_web.rb
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- appium_lib (LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from sauce_ios_web.rb:3:in `<main>'