Skip to content

Instantly share code, notes, and snippets.

View Piterden's full-sized avatar
🇷🇺
Stand with Russia!

Denis Efremov Piterden

🇷🇺
Stand with Russia!
View GitHub Profile
@fesor
fesor / ARTICLE.md
Created August 19, 2017 08:45
Возвращаясь к основам: почему юнит тесты это сложно

https://simpleprogrammer.com/2010/12/12/back-to-basics-why-unit-testing-is-hard/

Back to Basics: Why Unit Testing is Hard

перевод адаптирован под 2017-ый, где у нас нет проблем с mock фреймворками, и нам не обязательно создавать интерфейс дабы сделать мок.

Возвращаясь к основам: почему юнит тесты это сложно

@akrisanov
akrisanov / bcoin_client.py
Last active November 29, 2022 11:27
Trading cryptocurrencies
import logging
from http import HTTPStatus
import requests
from mnemonic import Mnemonic
class BcoinClient:
"""
Simple wrapper around Bcoin REST API.
@VladStepanov
VladStepanov / Promise impletementation.js
Last active February 9, 2020 11:48
Promise implementation
class MyPromise {
constructor(executor) {
this.state = MyPromise.states.pending
this.queue = {
'resolve': [],
'reject': []
}
try {
executor(this.resolver.bind(this), this.rejecter.bind(this))
} catch (e) {
local layout = require 'awful.widget.keyboardlayout'
local menubar = require 'menubar'
local kbdlayout = {
globally_preferred = 'us',
menubar_preferred = 'us',
}
local function get_idx_by_name(name)