Skip to content

Commit

Permalink
Improve unit test for go wrapper (#752)
Browse files Browse the repository at this point in the history
Why I did it
sonic-gnmi will break if any header file contains 'common' in path

How I did it
Improve unit test to detect common path issue

How to verify it
Pass all UT and E2E test cases.
  • Loading branch information
ganglyu authored Feb 28, 2023
1 parent 565ad4b commit 619d4ec
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion goext/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export CGO_LDFLAGS := -lswsscommon -lhiredis
export CGO_CXXFLAGS := -I../ -I../common/ -w -Wall -fpermissive
export CGO_CXXFLAGS := -I/usr/include/swss/ -w -Wall -fpermissive

GO ?= /usr/local/go/bin/go
SWIG ?= /usr/bin/swig
Expand All @@ -17,6 +17,7 @@ all:
$(SWIG) $(SWIG_FLAG) -I/usr/include/swss/ swsscommon.i

check:
sudo CGO_LDFLAGS="$(CGO_LDFLAGS)" CGO_CXXFLAGS="$(CGO_CXXFLAGS)" $(GO) build
sudo CGO_LDFLAGS="$(CGO_LDFLAGS)" CGO_CXXFLAGS="$(CGO_CXXFLAGS)" $(GO) test

clean:
Expand Down

0 comments on commit 619d4ec

Please sign in to comment.