Compare commits
13 Commits
61793f5ffb
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| ce0dbdfe7c | |||
| d8ae8cd017 | |||
| 65c6d44a6c | |||
| ffa906d9cc | |||
| a42650be38 | |||
| 1b0663fa73 | |||
| 57482921b7 | |||
| c68f37f00f | |||
| fd0116c1f3 | |||
| a64d3645ba | |||
| 99d7acc8ef | |||
| 18592f3266 | |||
| e68913b1f6 |
@@ -4,7 +4,7 @@ jobs:
|
|||||||
build-images:
|
build-images:
|
||||||
runs-on: host-arch-x86_64
|
runs-on: host-arch-x86_64
|
||||||
steps:
|
steps:
|
||||||
- name: Debug print
|
- name: Debug
|
||||||
run: echo '${{toJson(gitea)}}'
|
run: echo '${{toJson(gitea)}}'
|
||||||
|
|
||||||
- name: Clone repository
|
- name: Clone repository
|
||||||
@@ -12,17 +12,23 @@ jobs:
|
|||||||
|
|
||||||
- name: Build GCC container
|
- name: Build GCC container
|
||||||
working-directory: test5
|
working-directory: test5
|
||||||
run: docker build . -f Dockerfile -t local/alpine-gcc-${{gitea.ref_name}}:latest
|
run: docker build . -f Dockerfile -t local/alpine-gcc-${{gitea.sha}}:latest
|
||||||
|
|
||||||
run-tests:
|
run-tests:
|
||||||
runs-on: host-arch-x86_64
|
runs-on: host-arch-x86_64
|
||||||
needs: build-images
|
needs: build-images
|
||||||
#container: local/alpine-gcc:latest
|
|
||||||
steps:
|
steps:
|
||||||
- name: Clone repository
|
- name: Clone repository
|
||||||
run: git clone --revision ${{ gitea.sha }} --depth 1 ${{ gitea.server_url }}/${{ gitea.repository }}
|
run: git clone --revision ${{ gitea.sha }} --depth 1 ${{ gitea.server_url }}/${{ gitea.repository }}
|
||||||
|
|
||||||
- run: ls -lh test5
|
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: docker run -it --rm -v ./test5:/app local/alpine-gcc-${{gitea.ref_name}}:latest
|
run: docker run -it --rm -v ./test5:/app local/alpine-gcc-${{gitea.sha}}:latest
|
||||||
|
|
||||||
|
cleanup:
|
||||||
|
runs-on: host-arch-x86_64
|
||||||
|
needs: run-tests
|
||||||
|
if: ${{ always() }}
|
||||||
|
steps:
|
||||||
|
- name: Remove built container images
|
||||||
|
#if: ${{ always() }}
|
||||||
|
run: docker image rm local/alpine-gcc-${{gitea.sha}}:latest
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ size_t free_counter;
|
|||||||
|
|
||||||
void * TEST_MALLOC(size_t size)
|
void * TEST_MALLOC(size_t size)
|
||||||
{
|
{
|
||||||
printf("malloc'ed %lu\n", size);
|
//printf("malloc'ed %lu\n", size);
|
||||||
|
|
||||||
malloc_counter += size;
|
malloc_counter += size;
|
||||||
return malloc(size);
|
return malloc(size);
|
||||||
@@ -15,7 +15,7 @@ void * TEST_MALLOC(size_t size)
|
|||||||
void TEST_FREE(void *p)
|
void TEST_FREE(void *p)
|
||||||
{
|
{
|
||||||
size_t s = malloc_usable_size(p);
|
size_t s = malloc_usable_size(p);
|
||||||
printf("freed %lu\n", s);
|
//printf("freed %lu\n", s);
|
||||||
|
|
||||||
free_counter += s;
|
free_counter += s;
|
||||||
|
|
||||||
@@ -26,6 +26,7 @@ void TEST_FREE(void *p)
|
|||||||
#define free TEST_FREE
|
#define free TEST_FREE
|
||||||
int f(void)
|
int f(void)
|
||||||
{
|
{
|
||||||
|
malloc(16);
|
||||||
free(malloc(16));
|
free(malloc(16));
|
||||||
free(malloc(32));
|
free(malloc(32));
|
||||||
free(malloc(48));
|
free(malloc(48));
|
||||||
|
|||||||
Reference in New Issue
Block a user