Makefile with unit tests
Skip examples in unit tests Change-Id: I4e5673a33d45acaf13e3b08ff7b18d6bbf59a973
This commit is contained in:
parent
bff51c47ce
commit
d6e0b326e1
|
@ -0,0 +1,45 @@
|
||||||
|
# golang-client Makefile
|
||||||
|
# Follows the interface defined in the Golang CTI proposed
|
||||||
|
# in https://review.openstack.org/410355
|
||||||
|
|
||||||
|
#REPO_VERSION?=$(shell git describe --tags)
|
||||||
|
|
||||||
|
GIT_HOST = git.openstack.org
|
||||||
|
|
||||||
|
PWD := $(shell pwd)
|
||||||
|
TOP_DIR := $(shell basename $(PWD))
|
||||||
|
export GOPATH := $(PWD)-gopath
|
||||||
|
DEST := $(GOPATH)/src/$(GIT_HOST)/openstack/$(TOP_DIR).git
|
||||||
|
|
||||||
|
env:
|
||||||
|
@echo "PWD: $(PWD)"
|
||||||
|
@echo "TOP_DIR: $(TOP_DIR)"
|
||||||
|
@echo "GOPATH: $(GOPATH)"
|
||||||
|
@echo "DEST: $(DEST)"
|
||||||
|
|
||||||
|
work: $(GOPATH)
|
||||||
|
|
||||||
|
$(GOPATH):
|
||||||
|
mkdir -p $(shell dirname $(DEST))
|
||||||
|
ln -s $(PWD) $(DEST)
|
||||||
|
|
||||||
|
get: work
|
||||||
|
cd $(DEST); go get -tags=unit -t ./...
|
||||||
|
|
||||||
|
test: get
|
||||||
|
cd $(DEST); go test -tags=unit ./...
|
||||||
|
|
||||||
|
fmt:
|
||||||
|
cd $(DEST); go fmt ./...
|
||||||
|
|
||||||
|
cover:
|
||||||
|
@echo "$@ not yet implemented"
|
||||||
|
|
||||||
|
docs:
|
||||||
|
@echo "$@ not yet implemented"
|
||||||
|
|
||||||
|
relnotes:
|
||||||
|
@echo "Reno not yet implemented for this repo"
|
||||||
|
|
||||||
|
translation:
|
||||||
|
@echo "$@ not yet implemented"
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build !unit
|
||||||
|
|
||||||
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build !unit
|
||||||
|
|
||||||
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build !unit
|
||||||
|
|
||||||
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build !unit
|
||||||
|
|
||||||
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
// +build !unit
|
||||||
|
|
||||||
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
// Copyright (c) 2014 Hewlett-Packard Development Company, L.P.
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
// Licensed under the Apache License, Version 2.0 (the "License"); you may
|
||||||
|
|
Loading…
Reference in New Issue