File tree Expand file tree Collapse file tree 7 files changed +34
-8
lines changed Expand file tree Collapse file tree 7 files changed +34
-8
lines changed Original file line number Diff line number Diff line change 34
34
run : |
35
35
cd examples/
36
36
make
37
+ - name : Create k8s kind cluster
38
+
39
+ - name : Test examples
40
+ run : |
41
+ cd examples/
42
+ LD_LIBRARY_PATH=$GITHUB_WORKSPACE/kubernetes/build/ make test
Original file line number Diff line number Diff line change @@ -19,3 +19,10 @@ clean:
19
19
cd auth_provider; make clean
20
20
cd watch_list_pod; make clean
21
21
cd multi_thread; make clean
22
+
23
+ test :
24
+ cd create_pod; make test ; sleep 10
25
+ cd list_pod; make test
26
+ cd delete_pod; make test
27
+ cd generic; make test
28
+ cd multi_thread; make test
Original file line number Diff line number Diff line change 1
1
INCLUDE: =-I../../kubernetes/include -I../../kubernetes/model -I../../kubernetes/api -I../../kubernetes/config
2
2
LIBS: =-L../../kubernetes/build -lkubernetes -lyaml
3
3
CFLAGS: =-g
4
+ BIN: =create_pod_bin
4
5
5
6
all :
6
- gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o create_pod_bin
7
+ gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o $( BIN )
7
8
clean :
8
- rm ./create_pod_bin
9
+ rm ./$(BIN )
10
+ test :
11
+ ./$(BIN )
Original file line number Diff line number Diff line change 7
7
gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o $(BIN )
8
8
clean :
9
9
rm ./$(BIN )
10
+ test :
11
+ ./$(BIN )
Original file line number Diff line number Diff line change 1
1
INCLUDE: =-I../../kubernetes/include -I../../kubernetes/model -I../../kubernetes/api -I../../kubernetes/config
2
2
LIBS: =-L../../kubernetes/build -lkubernetes -lyaml
3
3
CFLAGS: =-g
4
+ BIN: =generic_bin
4
5
5
6
all :
6
- gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o generic_bin
7
+ gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o $( BIN )
7
8
clean :
8
- rm ./generic_bin
9
+ rm ./$(BIN )
10
+ test :
11
+ ./$(BIN )
Original file line number Diff line number Diff line change 1
1
INCLUDE: =-I../../kubernetes/include -I../../kubernetes/model -I../../kubernetes/api -I../../kubernetes/config
2
2
LIBS: =-L../../kubernetes/build -lkubernetes -lyaml
3
3
CFLAGS: =-g
4
+ BIN: =list_pod_bin
4
5
5
6
all :
6
- gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o list_pod_bin
7
+ gcc main.c $(CFLAGS ) $(INCLUDE ) $(LIBS ) -o $( BIN )
7
8
clean :
8
- rm ./list_pod_bin
9
+ rm ./$(BIN )
10
+ test :
11
+ ./$(BIN )
Original file line number Diff line number Diff line change @@ -11,6 +11,8 @@ all: $(OBJECTS)
11
11
$(OBJECTS ) : % .o: % .c
12
12
$(CC ) $(CFLAGS ) $(INCLUDE ) -c $< -o $@
13
13
14
- .PHONY : clean
14
+ .PHONY : clean test
15
15
clean :
16
- rm $(BIN ) $(OBJECTS )
16
+ rm $(BIN ) $(OBJECTS )
17
+ test :
18
+ ./$(BIN )
You can’t perform that action at this time.
0 commit comments