Skip to content

Instantly share code, notes, and snippets.

View darkofabijan's full-sized avatar

Darko Fabijan darkofabijan

View GitHub Profile
apiVersion: v1alpha
kind: Dashboard
metadata:
name: my-dashboard
title: My Dashboard
id: eb0cc2c7-bbc9-41e4-9e3d-2eb622a673fb
create_time: "1537888191"
update_time: "1537889560"
spec:
widgets:

Biggest sources of flaky tests (from our experience)

FactoryGirl

When using FactoryGirl to create records in tests, it is necessary to be aware that you are usually creating a lot more records than is obvious in the code. While this is usually harmless aside from slowing down tests, it is capable of creating some mind boggling flakiness. Some scenarios where this is probable are tests that count the number of records, tests that are expecting a certain record and assume that only it exists. Improperly set model level validations can also contribute to this.

Timestamps

@darkofabijan
darkofabijan / gist:7157148244c3ec0cb43a
Created December 1, 2015 20:58 — forked from vrinek/gist:bda51f6fc8b22b5df301
Blizzard Software Engineering Reading

Blizzard Software Engineering Reading

by Jay Baxter (circa 2009)

Associate developer

"This list is for people who want to become Associate Software Engineers at Blizzard. An associate should have skills at the level indicated by these books. Note that this is almost completely focused on C++ programming. This list is incomplete. I need a book on how to become a professional. I've listed several books that give examples of professional behavior, but not one on the actual training."

Programming: Principles and Practice Using C++

by Bjarne Stroustrup

@darkofabijan
darkofabijan / cs.md
Last active August 29, 2015 14:17
C# instalation

Add following lines to your build commands:

sudo apt-add-repository -y ppa:ermshiperete/monodevelop
sudo apt-get install -y monodevelop
@darkofabijan
darkofabijan / install.sh
Last active August 29, 2015 14:09
Upgrade phantomjs
sudo rm -rf /usr/local/phantomjs-1.9.7-linux-x86_64/bin/phantomjs
sudo rm -rf /usr/local/bin/phantomjs
curl -OL https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.8-linux-x86_64.tar.bz2
sudo tar -xjf phantomjs-1.9.8-linux-x86_64.tar.bz2 -C /usr/local/
sudo ln -s /usr/local/phantomjs-1.9.8-linux-x86_64/bin/phantomjs /usr/local/bin/phantomjs
rm -rf phantomjs-1.9.8-linux-x86_64.tar.bz2
@darkofabijan
darkofabijan / speaker.md
Last active August 29, 2015 13:57 — forked from matiaskorhonen/speaker.md
Creating a blog in 15 minutes with Phoenix

Darko Fabijan

Contact details

Speaker bio

I am developer and cofounder of Rendered Text, a company that you might know by Semaphore, hosted continuous integration service. I have been working with Rails since 2008, and got pushed into distributed systems arena while trying solve problems of fault-tolerant nodes, realtime updates and fast multi-node deployments that we were facing on Semaphore. While exploring distributed systems I discovered Elixir and joined the Phoenix core team.

resources :containers
namespace :admin do
resources :containers
end
containers GET /containers(.:format) containers#index
POST /containers(.:format) containers#create
new_container GET /containers/new(.:format) containers#new
edit_container GET /containers/:id/edit(.:format) containers#edit
iex(33)> Code.eval_quoted(quote do: [unquote_splicing([{4, "show/:id"}])])
{[{4, "show/:id"}], []}
iex(34)> Code.eval_quoted(quote do: [unquote_splicing([{4, "show/:id", 1, 2}])])
** (CompileError) nofile: invalid quoted expression: {4, "show/:id", 1, 2}
(elixir) src/elixir_exp.erl:408: :elixir_exp.expand_arg/2
(elixir) src/elixir_exp.erl:384: :elixir_exp.expand_list/4
(elixir) src/elixir_exp.erl:358: :elixir_exp.expand/2
(elixir) src/elixir.erl:150: :elixir.quoted_to_erl/3
(elixir) src/elixir.erl:134: :elixir.eval_forms/4
defmodule MyApp.Router do
use Phoenix.Router
namespace MyApp.Controllers do
get "restaurants/:id", Restaurants, :show, as: :restaurant
resources :images
resources :users, Accounts

Typography

Headings

Headings from h1 through h6 are constructed with a # for each level:

# h1 Heading
## h2 Heading
### h3 Heading