Skip to content

Instantly share code, notes, and snippets.

View ngtk's full-sized avatar
🏠
Working from home

Kento Nagata ngtk

🏠
Working from home
View GitHub Profile
@ngtk
ngtk / talking_points_when_visiting_companies.md
Last active June 20, 2021 06:29
話を聞きに行くときに訊くこと

話を聞きに行くときに訊くこと

働き方

  • 勤務時間は決まっていますか?
  • メンバーの平均勤務時間帯は何時から何時ですか?
  • リモートは可能ですか?
  • 具体的にどのようなケースでリモートをしていますか?

開発環境

  • 使用するPCは選べる?Macは許容される?アプリケーションは自由に入れられる?
@ngtk
ngtk / Accessible.swift
Created May 15, 2019 09:12
`Accessible` provides the way to find the element by a consistent name in UI tests.
import UIKit
/**
`Accessible` provides the way to find the element by a consistent name
in UI tests.
`generateAccessibilityIdentifiers()` creates the identifier that forms
the combination of the class name and the property name that is styled
like "ClassName.propertyName" and sets it to `accessibilityIdentifier`
to each property that is UIView.
signUpPage
.typeEmail("")
.typePassword("3i&wu,iu87n")
.then { XCTAssertEqual(signUpPage.errorMessage, "Email can't be blank.") }
class WelcomePage: Page {
// ...
private var loginButton: XCUIElement { return view.buttons["loginButton"] }
private var signUpButton: XCUIElement { return view.buttons["signUpButton"] }
func tapLoginButton() -> LoginPage {
loginButton.tap()
return LoginPage(app: app)
}
protocol Page {
var app: XCUIApplication { get }
var view: XCUIElement { get }
init(app: XCUIApplication)
}
func testSignup() {
let app = XCUIApplication()
let signUpPage = WelcomePage(app: app)
let completePage = signUpPage.
.typeEmail("smith@example.com")
.typePassword("jg28hwm90iflz")
.typeName("Smith")
func testSignup() {
let app = XCUIApplication()
// Start from welcome page
app.buttons["Signup"].tap()
// Move to sign up page
let emailField = app.textFields["emailField"]
let passwordField = app.secureTextFields["passwordField"]
let nameField = app.textFields["nameField"]
@ngtk
ngtk / miloshadzic.zsh-theme
Last active May 3, 2017 08:32
miloshadzic.zsh-theme
# from https://github.com/robbyrussell/oh-my-zsh/blob/master/themes/miloshadzic.zsh-theme
# Yay! High voltage and arrows!
ZSH_THEME_GIT_PROMPT_PREFIX="%{$reset_color%}%{$fg[green]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%} "
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[yellow]%}⚡%{$reset_color%}"
ZSH_THEME_GIT_PROMPT_CLEAN=""
PROMPT='%{$fg[cyan]%}%1~%{$reset_color%}%{$fg[red]%}|%{$reset_color%}$(git_prompt_info)%{$fg[cyan]%}⇒%{$reset_color%} '
@ngtk
ngtk / my-review-policy.md
Last active December 31, 2016 13:43
My Review Policy

My Review Policy

これは何?

コードレビューでのコミュニケーションを円滑にするために自分の方針を明確にするためです。この文章ではレビューイ、レビュワー双方の立場での振る舞い両方を示すものとします。

レビューの目的

  • 読みやすいコードを実現するため
  • ロジックの矛盾やケースの抜け漏れを見つけるため
@ngtk
ngtk / flexbox.md
Last active November 23, 2016 09:02
逆引きflexbox

基本

横に並べる(デフォルト)

  • flex-direction: row;
.flex-container {
  display: flex;
  flex-direction: row;
}