Skip to content

Instantly share code, notes, and snippets.

View shoesCodeFor's full-sized avatar

Schuyler Ankele shoesCodeFor

View GitHub Profile
@DanielGallo
DanielGallo / Classes.js
Last active July 17, 2018 15:05
Using and checking classes in Sencha Test on Components and Elements
// Scenario URL: http://examples.sencha.com/extjs/6.5.3/examples/kitchensink/?classic#form-contact
describe('Check component and element classes', function() {
it('should check the class applied to a component configuration', function() {
// These examples reference an Ext JS component and check its configured classes
// Example 1
ST.button('form-contact button[text="Contact Us"]')
.get('cls')
.and(function(future) {
expect(future.data.cls).toContain('contactBtn');
@DanielGallo
DanielGallo / MouseOver.js
Last active January 28, 2019 20:37
MouseOver on Component in WebDriver scenario (Sencha Test)
// Scenario URL: http://examples.sencha.com/extjs/6.5.3/examples/kitchensink/frame-index.html?classic#locking-grid
describe('Grid column tests', function() {
it('Should lock the Change column', function() {
var driver = ST.defaultContext.driver;
// This code moves the mouse over one of the column's headers which
// shows the trigger to display the column menu
ST.element('gridcolumn[text=Change] => .x-column-header-text-container')
.get('id')
.and(function() {
@brycemcd
brycemcd / openzoom.zsh
Created December 14, 2016 15:34
Opens a zoom meeting in a browser from the command line
#!/bin/zsh
# Opens a zoom meeting with the name you've given it.
# Drop this script in /usr/local/bin/openzoom
# Invoke with `openzoom meeting_name`
typeset -A meeting
# NOTE: set this hashmap with meeting_name and ids of that meeting
meeting[meeting_name]=123456789
@tevino
tevino / fix_virtualenv
Last active March 24, 2024 09:41
Fix python virtualenv after python update
#!/usr/bin/env bash
ENV_PATH="$(dirname "$(dirname "$(which pip)")")"
SYSTEM_VIRTUALENV="$(which -a virtualenv|tail -1)"
BAD_ENV_PATHS="/usr/local"
echo "Ensure the root of the broken virtualenv:"
echo " $ENV_PATH"
@halloffame
halloffame / RubyDateFormats.md
Last active May 25, 2024 13:38
Quick reference for ruby date format abbreviations.

Date

Year

%Y - Year with century (can be negative, 4 digits at least) -0001, 0000, 1995, 2009, 14292, etc.

  • %C - year / 100 (round down. 20 in 2009)
  • %y - year % 100 (00..99)