-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dev' into Handler/Network
- Loading branch information
Showing
33 changed files
with
684 additions
and
448 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
name: 'Build libraries' | ||
|
||
on: | ||
push: | ||
branches: | ||
- '**' | ||
paths: | ||
- '.github/workflows/**' | ||
- 'cmake/**' | ||
- 'include/**' | ||
- 'src/**' | ||
- 'tests/**' | ||
- '**/CMakeLists.txt' | ||
- '**/*.pro' | ||
pull_request: | ||
branches: | ||
- '**' | ||
paths: | ||
- '.github/workflows/**' | ||
- 'cmake/**' | ||
- 'include/**' | ||
- 'src/**' | ||
- 'tests/**' | ||
- '**/CMakeLists.txt' | ||
- '**/*.pro' | ||
|
||
defaults: | ||
run: | ||
shell: pwsh | ||
|
||
jobs: | ||
build-libraries: | ||
name: 'Build libraries' | ||
|
||
strategy: | ||
matrix: | ||
include: | ||
- { system: windows-latest, config: Debug, cc: cl, cpp: cl } | ||
- { system: windows-latest, config: Release, cc: cl, cpp: cl } | ||
- { system: windows-latest, config: Debug, cc: gcc, cpp: g++ } | ||
- { system: windows-latest, config: Release, cc: gcc, cpp: g++ } | ||
- { system: ubuntu-latest, config: Debug, cc: gcc-11, cpp: g++-11 } | ||
- { system: ubuntu-latest, config: Release, cc: gcc-11, cpp: g++-11} | ||
- { system: ubuntu-latest, config: Debug, cc: clang-14, cpp: clang++-14 } | ||
- { system: ubuntu-latest, config: Release, cc: clang-14, cpp: clang++-14 } | ||
fail-fast: false | ||
|
||
runs-on: ${{ matrix.system }} | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup Visual Studio Build Tools | ||
uses: ilammy/msvc-dev-cmd@v1 | ||
if: ${{ runner.os == 'Windows' && matrix.cc == 'cl' }} | ||
|
||
- name: Setup MSYS2 | ||
uses: msys2/setup-msys2@v2 | ||
if: ${{ runner.os == 'Windows' && matrix.cc == 'gcc' }} | ||
with: | ||
msystem: UCRT64 | ||
update: true | ||
install: mingw-w64-ucrt-x86_64-gcc | ||
|
||
- name: Setup GCC and Clang | ||
if: ${{ runner.os == 'Linux' }} | ||
run: | | ||
sudo apt update && ` | ||
sudo apt install -y ` | ||
gcc-11 ` | ||
g++-11 ` | ||
clang-14 | ||
- name: Setup Ninja | ||
uses: imesense/[email protected] | ||
|
||
- name: Configure project | ||
run: | | ||
cmake ` | ||
-S . ` | ||
-B build ` | ||
-G "Ninja" ` | ||
-DCMAKE_C_COMPILER=${{ matrix.cc }} ` | ||
-DCMAKE_CXX_COMPILER=${{ matrix.cpp }} ` | ||
-DFLAME_CONAN_SUPPORT=OFF ` | ||
-DCMAKE_BUILD_TYPE=${{ matrix.config }} | ||
- name: Build project | ||
run: | | ||
cmake ` | ||
--build build ` | ||
--config ${{ matrix.config }} | ||
- name: Run tests | ||
run: | | ||
cmake ` | ||
--build build ` | ||
--target test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
image: | ||
name: debian:bookworm-slim | ||
|
||
clone: | ||
depth: 1 | ||
|
||
pipelines: | ||
default: | ||
- step: | ||
name: Install toolchain | ||
script: | ||
- apt update | ||
- apt install -y g++ cmake ninja-build git | ||
- mkdir build | ||
- cd build | ||
- cmake -S .. -B . -GNinja -DFLAME_CONAN_SUPPORT=OFF -DCMAKE_BUILD_TYPE=Release | ||
- cmake --build . | ||
# artifacts: | ||
# - build/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
#include <FlameIDE/../../src/Common/Tests/VoidTypeTest.hpp> | ||
|
||
namespace flame_ide | ||
{namespace common | ||
{namespace tests | ||
{ | ||
|
||
struct ExistMember | ||
{ | ||
int member = 0; | ||
}; | ||
|
||
struct NotExistMember | ||
{}; | ||
|
||
template<class T, class = VoidType<>> | ||
struct HasMemember: public FalseType | ||
{}; | ||
|
||
template<class T> | ||
struct HasMemember<T, VoidType<decltype(&T::member)>>: public TrueType | ||
{}; | ||
|
||
VoidTypeTest::VoidTypeTest() : AbstractTest("VoidType") | ||
{} | ||
|
||
VoidTypeTest::~VoidTypeTest() = default; | ||
|
||
int VoidTypeTest::vStart() | ||
{ | ||
IN_CASE_CHECK(HasMemember<ExistMember>::VALUE == TrueType::VALUE); | ||
IN_CASE_CHECK_END(HasMemember<NotExistMember>::VALUE == FalseType::VALUE); | ||
} | ||
|
||
}}} // flame_ide::common::tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
#ifndef FLAMEIDE_COMMON_TESTS_VOIDTYPETEST_HPP | ||
#define FLAMEIDE_COMMON_TESTS_VOIDTYPETEST_HPP | ||
|
||
#include <FlameIDE/Common/Traits/Defaults.hpp> | ||
|
||
#include <tests/Test.hpp> | ||
|
||
namespace flame_ide | ||
{namespace common | ||
{namespace tests | ||
{ | ||
|
||
class VoidTypeTest: public AbstractTest | ||
{ | ||
public: | ||
VoidTypeTest(); | ||
virtual ~VoidTypeTest(); | ||
|
||
private: | ||
virtual int vStart(); | ||
}; | ||
|
||
}}} // flame_ide::common::tests | ||
|
||
#endif // FLAMEIDE_COMMON_TESTS_VOIDTYPETEST_HPP |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.