Skip to content

Commit

Permalink
action to bulid + test (#194)
Browse files Browse the repository at this point in the history
* action to bulid + test

* memcmp compilcation error

* strcmp

* memcpy

* and also this comment
  • Loading branch information
galkahana authored Feb 17, 2023
1 parent 9d36660 commit 1ffa94e
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 2 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: CMake

on:
push:
branches: [ "*" ]
pull_request:
branches: [ "master" ]

env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: Release

jobs:
build:
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Configure CMake
# Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}

- name: Build
# Build your program with the given configuration
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}

- name: Test
working-directory: ${{github.workspace}}/build
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: ctest -C ${{env.BUILD_TYPE}}

1 change: 1 addition & 0 deletions PDFWriterTesting/AppendingAndReading.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "testing/TestIO.h"

#include <iostream>
#include <memory.h>

using namespace PDFHummus;
using namespace std;
Expand Down
2 changes: 1 addition & 1 deletion PDFWriterTesting/DCTDecodeFilterTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ int DCTDecodeFilterTest(int argc, char* argv[])
return status == eSuccess ? 0:1;
}

#else PDFHUMMUS_NO_DCT
#else // PDFHUMMUS_NO_DCT

int DCTDecodeFilterTest(int argc, char* argv[]) {
return 0;
Expand Down
2 changes: 1 addition & 1 deletion PDFWriterTesting/FlateEncryptionTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
#include "OutputStreamTraits.h"

#include <iostream>

#include <string.h>

#include "testing/TestIO.h"

Expand Down
1 change: 1 addition & 0 deletions PDFWriterTesting/PDFObjectParserTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ limitations under the License.

#include <iostream>
#include <sstream>
#include <memory.h>

#include "testing/TestIO.h"

Expand Down

0 comments on commit 1ffa94e

Please sign in to comment.