Formatting updates.
This commit is contained in:
parent
5f5d24a6b1
commit
db1ce5f0fe
20
capybara.md
20
capybara.md
|
@ -3,17 +3,17 @@ title: Capybara
|
|||
layout: default
|
||||
---
|
||||
|
||||
### Navigating
|
||||
## Navigating
|
||||
|
||||
visit articles_path
|
||||
|
||||
### Clicking links and buttons
|
||||
## Clicking links and buttons
|
||||
|
||||
click 'Link Text'
|
||||
click_button
|
||||
click_link
|
||||
|
||||
### Interacting with forms
|
||||
## Interacting with forms
|
||||
|
||||
attach_file
|
||||
fill_in 'First Name', :with => 'John'
|
||||
|
@ -23,7 +23,7 @@ layout: default
|
|||
select
|
||||
unselect
|
||||
|
||||
### Querying
|
||||
## Querying
|
||||
|
||||
Takes a CSS selector (or XPath if you're into that).
|
||||
Translates nicely into RSpec matchers:
|
||||
|
@ -52,7 +52,7 @@ should_not doesn't wait for a timeout from the driver
|
|||
page.has_select?
|
||||
page.has_no_select?
|
||||
|
||||
### Finding
|
||||
## Finding
|
||||
|
||||
find
|
||||
find_button
|
||||
|
@ -61,7 +61,7 @@ should_not doesn't wait for a timeout from the driver
|
|||
find_link
|
||||
locate
|
||||
|
||||
### Scoping
|
||||
## Scoping
|
||||
|
||||
within
|
||||
within_fieldset
|
||||
|
@ -69,16 +69,16 @@ should_not doesn't wait for a timeout from the driver
|
|||
within_frame
|
||||
scope_to
|
||||
|
||||
### Scripting
|
||||
## Scripting
|
||||
|
||||
execute_script
|
||||
evaluate_script
|
||||
|
||||
### Debugging
|
||||
## Debugging
|
||||
|
||||
save_and_open_page
|
||||
|
||||
### Miscellaneous
|
||||
## Miscellaneous
|
||||
|
||||
all
|
||||
body
|
||||
|
@ -89,7 +89,7 @@ should_not doesn't wait for a timeout from the driver
|
|||
wait_until
|
||||
current_path
|
||||
|
||||
### Capybara RSpec matchers
|
||||
## Capybara RSpec matchers
|
||||
|
||||
expect(page).to have_button
|
||||
expect(page).to have_checked_field
|
||||
|
|
|
@ -3,7 +3,7 @@ title: Make for assets
|
|||
layout: default
|
||||
---
|
||||
|
||||
### Basic compiling
|
||||
## Basic compiling
|
||||
|
||||
bin := ./node_modules/.bin
|
||||
|
||||
|
@ -12,7 +12,7 @@ layout: default
|
|||
build/%.js: src/%.coffee
|
||||
@$(bin)/coffee < $^ > $@
|
||||
|
||||
### Stylus + Autoprefixer
|
||||
## Stylus + Autoprefixer
|
||||
|
||||
bin := ./node_modules/.bin
|
||||
stylus := $(bin)/stylus
|
||||
|
@ -26,18 +26,18 @@ layout: default
|
|||
%.css: %.styl $(styl_files)
|
||||
@$(stylus) $< | $(autoprefixer) -b "> 1%" > $@
|
||||
|
||||
### Hint
|
||||
## Hint
|
||||
|
||||
hint:
|
||||
$(js_files)
|
||||
|
||||
### Watching
|
||||
## Watching
|
||||
|
||||
watch:
|
||||
@echo "... watching for changes"
|
||||
@while true; do make -s; sleep 1; done
|
||||
|
||||
### Browserify
|
||||
## Browserify
|
||||
|
||||
js_files := $(shell find web/ -name "*.js")
|
||||
|
||||
|
|
20
makefile.md
20
makefile.md
|
@ -3,13 +3,13 @@ title: Makefile
|
|||
layout: default
|
||||
---
|
||||
|
||||
### Var assignment
|
||||
## Var assignment
|
||||
|
||||
uglify = $(uglify) # assignment
|
||||
compressor := $(uglify) # lazy assignment
|
||||
prefix ?= /usr/local # safe assignment
|
||||
|
||||
### Magic variables
|
||||
## Magic variables
|
||||
|
||||
out.o: src.c src.h
|
||||
$@ - "out.o" (target)
|
||||
|
@ -27,7 +27,7 @@ layout: default
|
|||
|
||||
$(@D) - target directory
|
||||
|
||||
### Command prefixes
|
||||
## Command prefixes
|
||||
|
||||
- Ignore errors
|
||||
@ Don't print command
|
||||
|
@ -39,12 +39,12 @@ layout: default
|
|||
|
||||
-include .depend
|
||||
|
||||
### Find files
|
||||
## Find files
|
||||
|
||||
js_files := $(wildcard test/*.js)
|
||||
all_files := $(shell find images -name "*")
|
||||
|
||||
### Substitutions
|
||||
## Substitutions
|
||||
|
||||
file = $(SOURCE:.cpp=.o) # foo.cpp => foo.o
|
||||
outputs = $(files:src/%.coffee=lib/%.js)
|
||||
|
@ -52,24 +52,24 @@ layout: default
|
|||
outputs = $(patsubst %.c, %.o, $(wildcard *.c))
|
||||
assets = $(patsubst images/%, assets/%, $(wildcard images/*))
|
||||
|
||||
### More functions
|
||||
## More functions
|
||||
|
||||
$(strip $(string_var))
|
||||
|
||||
$(filter %.less, $(files))
|
||||
$(filter-out %.less, $(files))
|
||||
|
||||
### Building files
|
||||
## Building files
|
||||
|
||||
%.o: %.c
|
||||
ffmpeg -i $< > $@ # Input and output
|
||||
foo $^
|
||||
|
||||
### Includes
|
||||
## Includes
|
||||
|
||||
-include foo.make
|
||||
|
||||
### Options
|
||||
## Options
|
||||
|
||||
make
|
||||
-e, --environment-overrides
|
||||
|
@ -78,7 +78,7 @@ layout: default
|
|||
|
||||
-j, --jobs=N # parallel processing
|
||||
|
||||
### Conditionals
|
||||
## Conditionals
|
||||
|
||||
foo: $(objects)
|
||||
ifeq ($(CC),gcc)
|
||||
|
|
Loading…
Reference in New Issue