Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .clang-format
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ AlignTrailingComments:
Kind: Never

# Accolades
RemoveBracesLLVM: true
RemoveBracesLLVM: false

# Order
SortIncludes: CaseInsensitive
Expand Down
13 changes: 12 additions & 1 deletion .github/workflows/ci-cpp-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ jobs:
build:
name: Ubuntu (${{ matrix.compiler.name }})
runs-on: ubuntu-latest
permissions:
contents: read
issues: read
checks: write
pull-requests: write
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -71,4 +76,10 @@ jobs:

- name: Run tests
run: |
xmake run
xmake run CppUtils-UnitTests --report=junit:build/test-results.xml

- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
with:
files: "**/test-results.xml"
13 changes: 12 additions & 1 deletion .github/workflows/ci-cpp-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ jobs:
build:
name: MacOS (${{ matrix.compiler.name }})
runs-on: macos-latest
permissions:
contents: read
issues: read
checks: write
pull-requests: write
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -48,4 +53,10 @@ jobs:

- name: Run tests
run: |
xmake run
xmake run CppUtils-UnitTests --report=junit:build/test-results.xml

- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action/macos@v2
if: always()
with:
files: "**/test-results.xml"
13 changes: 12 additions & 1 deletion .github/workflows/ci-cpp-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ jobs:
build:
name: Windows (${{ matrix.compiler.name }})
runs-on: windows-latest
permissions:
contents: read
issues: read
checks: write
pull-requests: write
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -52,5 +57,11 @@ jobs:
- name: Run tests
shell: pwsh
run: |
xmake run
xmake run CppUtils-UnitTests --report=junit:build/test-results.xml

- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action/windows@v2
if: always()
with:
files: "**/test-results.xml"

4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
/docs/dist
/docs/.astro
/docs/doxygen_xml
/docs/html
/docs/latex
/docs/src/content/docs/**/reference/
/docs/src/data/cppreference-symbols.json
/docs/src/data/cpputils-symbols.json
/docs/.starlight-icons

9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,13 @@
- [`Variant`](modules/Type/Variant.mpp) - Generic print and comparison operators for `std::variant`

### 🧪 Unit Testing
- [`LifetimeChecker`](modules/UnitTest/LifetimeChecker.mpp) - Object that prints construction, destruction, copy and move operations, while counting copies and moves for test verification
- [`UnitTest`](modules/UnitTest/UnitTest.mpp) - Minimal test framework with assertions and filters
- [`Benchmark`](modules/UnitTest/Benchmark.mpp) - Benchmarking utilities with execution timing statistics and performance comparisons
- [`EventWatcher`](modules/UnitTest/EventWatcher.mpp) - Event observation and expectation verification for event-driven systems
- [`Expectation`](modules/UnitTest/Expectation.mpp) - Fluent assertion API (`expect(a) == b`, `throws`, `noThrow`, `crashes`, `eventually`, `completes`)
- [`JUnitFormatter`](modules/UnitTest/JUnitFormatter.mpp) - JUnit XML report generator for CI/CD test reporting
- [`LifetimeChecker`](modules/UnitTest/LifetimeChecker.mpp) - Diagnostic probe tracking object construction, destruction, copy and move counts
- [`Runner`](modules/UnitTest/Runner.mpp) - Test runner engine with process isolation, timeout enforcement, and dependency execution
- [`UnitTest`](modules/UnitTest/UnitTest.mpp) - Modern macro-free unit testing framework with declarative suite builders (`testSuite`), parameterized/typed suites, and compile-time test execution

### 🧩 Miscellaneous
- Many other functions
Expand Down
1 change: 1 addition & 0 deletions docs/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ EXTRACT_STATIC = YES
EXTRACT_PRIVATE = NO
QUIET = YES
WARNINGS = NO
PREDEFINED = OS_LINUX
30 changes: 24 additions & 6 deletions docs/astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,14 @@ import { starlightIconsPlugin, starlightIconsIntegration } from 'starlight-plugi
import UnoCSS from 'unocss/astro';
import mermaid from 'astro-mermaid';
import { remarkCppReference } from './src/plugins/remark-cppreference.mjs';
import { remarkCppUtils } from './src/plugins/remark-cpputils.mjs';
import { remarkTerminal } from './src/plugins/remark-terminal.mjs';

export default defineConfig({
site: 'https://morgancaron.github.io',
base: process.env.GITHUB_ACTIONS === 'true' ? '/CppUtils' : '/',
markdown: {
remarkPlugins: [remarkCppReference],
remarkPlugins: [remarkCppReference, remarkCppUtils, remarkTerminal],
},
integrations: [
starlight({
Expand All @@ -32,6 +34,8 @@ export default defineConfig({
fr: 'Retour en haut',
},
showTooltip: true,
borderRadius: '50',
svgStrokeWidth: 2,
}),
starlightAnnouncement({
displayMode: 'rotate',
Expand Down Expand Up @@ -141,18 +145,32 @@ gtag('config', 'G-9EYYYD173T', {
slug: 'guides/build-configuration',
},
{
label: 'RAII synchronization (Lockers)',
translations: { fr: 'Synchronisation RAII (Lockers)' },
label: 'Unit testing framework',
translations: { fr: 'Tests unitaires' },
slug: 'guides/unit-test',
},
{
label: 'RAII Lockers',
translations: { fr: 'Verrous RAII' },
slug: 'guides/lockers',
},
],
},
{
label: 'API reference',
label: 'CppUtils API reference',
translations: {
fr: 'Référence d’API',
fr: 'Référence d’API CppUtils',
},
items: [{ autogenerate: { directory: 'reference', collapsed: true } }],
items: [
{
label: 'CppUtils API reference',
translations: {
fr: 'Référence d’API CppUtils',
},
slug: 'reference',
},
{ autogenerate: { directory: 'reference', collapsed: true } },
],
},
],
}),
Expand Down
Loading
Loading