Skip to content

Commit

Permalink
Fixed doc generation & updated stubs
Browse files Browse the repository at this point in the history
  • Loading branch information
amercier committed Dec 4, 2013
1 parent b2381c1 commit db718dd
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ clean:
# ==============================================================================

# Linting
lint: all
lint: dependencies
vendor/bin/phpcs$(EXT) --standard=PSR1 src/ tests/ \
&& vendor/bin/phpcs$(EXT) --standard=PSR2 src/ tests/

Expand All @@ -70,7 +70,7 @@ tests/_files: tests/_files.tar.gz
tar xvfz tests/_files.tar.gz -C tests/_files

# Unit tests (using stubs)
test: vendor tests/_files
test: dependencies tests/_files
make lint \
&& vendor/bin/phpunit$(EXT) \
--coverage-html build/logs/coverage \
Expand All @@ -79,15 +79,15 @@ test: vendor tests/_files
&& $(SHOW_COVERAGE)

# Integration tests
integration: vendor
integration: dependencies
make lint \
&& vendor/bin/phpunit$(EXT) \
--coverage-html build/logs/coverage \
--coverage-text=build/logs/coverage.txt \
--configuration phpunit-integration.xml \

# Stubs (tests/_files.tar.gz) generation
stubs: vendor
stubs: dependencies
[ ! -d tests/_files ] || rm -Rf tests/_files \
&& [ ! -e tests/_files.tar.gz ] || rm -Rf tests/_files.tar.gz \
&& make lint \
Expand All @@ -98,14 +98,22 @@ stubs: vendor
# │ Generated stubs │
# └─────────────────┘

doc: vendor src

# ==============================================================================
# Documentation
# ==============================================================================

doc: $(DOC)
# ┌─────────────────────────────┐
# │ Documentation is up-to-date │
# └─────────────────────────────┘

$(DOC): dependencies src
[ ! -d "$(DOC)" ] || rm -Rf "$(DOC)"
mkdir -p "$(DOC)"
vendor/bin/phpdoc.php \
--directory src/ \
--target "$(DOC)" \
--title "vCloud PHP SDK Helpers" \
--template responsive-twig
# ┌─────────────────────────────┐
# │ Documentation is up-to-date │
# └─────────────────────────────┘
touch docs
Binary file modified tests/_files.tar.gz
Binary file not shown.

0 comments on commit db718dd

Please sign in to comment.