genofire/hs_monolith
genofire
/
hs_monolith
Archived
1
0
Fork 0

[TASK] add draft of ProductExists for a query to another microservice

This commit is contained in:
Martin Geno 2017-04-04 07:46:09 +02:00
parent 95c694225d
commit 1e03f95855
No known key found for this signature in database
GPG Key ID: F0D39A37E925E941
3 changed files with 144 additions and 1 deletions

129
.gitignore vendored
View File

@ -1,2 +1,129 @@
cmd/stock/config.conf
## Core latex/pdflatex auxiliary files:
*.aux
*.lof
*.log
*.lot
*.fls
*.out
*.toc
## Intermediate documents:
*.dvi
*-converted-to.*
# these rules might exclude image files for figures etc.
*.ps
*.eps
*.pdf
## Bibliography auxiliary files (bibtex/biblatex/biber):
*.bbl
*.bcf
*.blg
*-blx.aux
*-blx.bib
*.brf
*.run.xml
## Build tool auxiliary files:
*.fdb_latexmk
*.synctex
*.synctex.gz
*.synctex.gz(busy)
*.pdfsync
## Auxiliary and intermediate files from other packages:
# algorithms
*.alg
*.loa
# achemso
acs-*.bib
# amsthm
*.thm
# beamer
*.nav
*.snm
*.vrb
#(e)ledmac/(e)ledpar
*.end
*.[1-9]
*.[1-9][0-9]
*.[1-9][0-9][0-9]
*.[1-9]R
*.[1-9][0-9]R
*.[1-9][0-9][0-9]R
*.eledsec[1-9]
*.eledsec[1-9]R
*.eledsec[1-9][0-9]
*.eledsec[1-9][0-9]R
*.eledsec[1-9][0-9][0-9]
*.eledsec[1-9][0-9][0-9]R
# glossaries
*.acn
*.acr
*.glg
*.glo
*.gls
# hyperref
*.brf
# knitr
*-concordance.tex
*.tikz
*-tikzDictionary
# listings
*.lol
# makeidx
*.idx
*.ilg
*.ind
*.ist
# minitoc
*.maf
*.mtc
*.mtc0
# minted
_minted*
*.pyg
# morewrites
*.mw
# nomencl
*.nlo
# sagetex
*.sagetex.sage
*.sagetex.py
*.sagetex.scmd
# sympy
*.sout
*.sympy
sympy-plots-for-*.tex/
# todonotes
*.tdo
# xindy
*.xdy
__pycache__
# IDE's go
.idea/
# go project
cmd/stock/config.conf

View File

@ -1,5 +1,6 @@
package models
// TODO DRAFT for a rest request to a other microservice
func ProductExists(id int64) (bool, error) {
return true, nil
}

15
models/product_test.go Normal file
View File

@ -0,0 +1,15 @@
package models
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestProductExists(t *testing.T) {
assert := assert.New(t)
ok, err := ProductExists(3)
assert.True(ok)
assert.NoError(err)
}