Skip to content

Instantly share code, notes, and snippets.

@elikem
elikem / california_hvip.py
Last active August 19, 2024 02:47
Example of automated tests on https://californiahvip.org
# test to assert page title: is what is expected
# test to assert search button: test the presence of the search link
# test to assert presence of a searchable article: test the presence of a searchable article 'Evening Community Meeting'
import time
import unittest
import warnings
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.common.keys import Keys
@elikem
elikem / rails_model_template.rb
Created April 14, 2023 22:59 — forked from metalelf0/rails_model_template.rb
A rails model template to better organize your code
# provided by https://www.zmwolski.com/Organizing-Ruby-on-Rails-Models
class User < ActiveRecord::Base
# == Constants ============================================================
# == Attributes ===========================================================
# == Extensions ===========================================================
@elikem
elikem / vim-shortcuts.md
Created January 18, 2023 13:52 — forked from tuxfight3r/vim-shortcuts.md
VIM SHORTCUTS

VIM KEYBOARD SHORTCUTS

MOVEMENT

h        -   Move left
j        -   Move down
k        -   Move up
l        -   Move right
$        -   Move to end of line
0        -   Move to beginning of line (including whitespace)

Rails naming conventions

General Ruby conventions

Class names are CamelCase.

Methods and variables are snake_case.

Methods with a ? suffix will return a boolean.

@elikem
elikem / SpaceVim.md
Created August 19, 2022 03:35 — forked from bespokoid/SpaceVim.md
SpaceVim cheatsheet #tools
@elikem
elikem / git_cheat-sheet.md
Created September 12, 2020 22:25 — forked from davfre/git_cheat-sheet.md
git commandline cheat-sheet
@elikem
elikem / RAILS_CHEATSHEET.md
Created June 3, 2020 22:06 — forked from mdang/RAILS_CHEATSHEET.md
Ruby on Rails Cheatsheet

Ruby on Rails Cheatsheet

Architecture

Create a new application

Install the Rails gem if you haven't done so before

@elikem
elikem / RAILS_CHEATSHEET.md
Created June 3, 2020 22:06 — forked from mdang/RAILS_CHEATSHEET.md
Ruby on Rails Cheatsheet

Ruby on Rails Cheatsheet

Architecture

Create a new application

Install the Rails gem if you haven't done so before

@elikem
elikem / git_examples.sh
Created October 8, 2019 16:06
99% of the Git commands you'll need at work, demonstrated in a single script
#!/bin/bash
##########
# contents
##########
# contents
# notes
# script setup
# git config files