Skip to content

Cross-platform C++ desktop app for managing conference registrations with Qt Framework, featuring MVC architecture, XML persistence, and comprehensive test coverage

License

Notifications You must be signed in to change notification settings

mitchcamza/ConferenceRegistration

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Conference Registration System

CI License: MIT C++ Qt

πŸ“‹ Table of Contents

🎯 About This Project

Conference Registration is a cross-platform desktop application that streamlines the management of conference attendees. Built with C++ and the Qt Framework, this project demonstrates enterprise-level software engineering practices including object-oriented design, design patterns, and modern C++ development.

The Problem: Conference organizers need an efficient way to manage different types of registrations (standard, student, and guest), calculate fees, track attendance, and maintain registration data with import/export capabilities.

The Solution: A robust desktop application featuring:

  • Intuitive GUI for managing diverse registration types
  • Real-time filtering and search capabilities
  • XML-based serialization for data persistence
  • Automated fee calculation based on registration type
  • Cross-platform compatibility (Windows, macOS, Linux)

Built With:

  • Language: C++17
  • Framework: Qt 5/6 (Widgets)
  • Build System: CMake 3.5+
  • CI/CD: GitHub Actions
  • Documentation: Doxygen

πŸ’Ό Technical Skills Demonstrated

This project showcases proficiency in:

Core Programming

  • C++ Development: Modern C++17 features, STL usage, memory management
  • Object-Oriented Programming: Inheritance, polymorphism, abstraction, encapsulation
  • Design Patterns: Factory Pattern, Singleton Pattern, Model-View architecture

Software Architecture

  • Separation of Concerns: Clean separation between business logic, data models, and UI
  • SOLID Principles: Single Responsibility, Open/Closed, Liskov Substitution
  • MVC Pattern: Custom model implementation with Qt's Model/View framework

Qt Framework Expertise

  • Qt Widgets: Custom dialogs, main windows, interactive UI components
  • Qt Model/View: Custom QAbstractTableModel and proxy filtering
  • Signal/Slot Mechanism: Event-driven programming
  • Qt XML: Serialization and deserialization using QXmlStreamWriter and QXmlStreamReader

Development Practices

  • Build Automation: CMake for cross-platform builds
  • CI/CD: Automated builds and testing using GitHub Actions
  • Unit Testing: Comprehensive test suite using GoogleTest framework
  • UI Testing: Qt Test framework for GUI component testing
  • Code Coverage: lcov/genhtml integration with 81.5% line coverage
  • Version Control: Git with feature branch workflow
  • Documentation: Comprehensive Doxygen documentation
  • Code Quality: Consistent naming conventions, well-commented code

Additional Skills

  • Cross-Platform Development: Linux, Windows, macOS compatibility
  • File I/O Operations: XML parsing, file system operations
  • Data Filtering: Custom proxy models for real-time search
  • Resource Management: Qt resource system integration

πŸ”§ Key Technical Highlights

1. Factory Pattern Implementation

Implemented a singleton Factory class to create different registration types dynamically:

Registration *createRegistration(const QString &type, ...);

2. Custom Qt Model

Built a custom QAbstractTableModel to display registration data with real-time updates:

  • Overrode virtual methods (data(), headerData(), rowCount())
  • Integrated with Qt's Model/View architecture
  • Supports dynamic data insertion and filtering

3. Proxy Model for Filtering

Developed a custom QSortFilterProxyModel for real-time name-based filtering without modifying the underlying data model.

4. XML Serialization

Implemented complete serialization/deserialization system:

  • Custom XML schema design
  • Robust error handling for malformed files
  • Support for appending imported data

5. Polymorphic Design

Abstract Registration base class with three derived types demonstrating runtime polymorphism for fee calculations and data management.

6. Automated CI/CD

GitHub Actions workflow for automated building and unit testing on multiple branches, ensuring code quality and build stability.

7. Comprehensive Testing

Implemented a robust test suite with 61 tests covering unit, integration, and UI testing:

  • Unit Tests (42): Core domain logic including Person class, Registration types, and Factory pattern using GoogleTest
  • Integration Tests (16): End-to-end XML persistence with round-trip validation and fixture-based testing using GoogleTest
  • UI Tests (3 suites, 38 test functions): Qt-based UI component testing using Qt Test framework
  • Tests run automatically in CI pipeline ensuring code quality and preventing regressions

8. Code Coverage Reporting

Integrated code coverage reporting using lcov/genhtml:

  • Achieves 81.5% line coverage and 78.8% function coverage
  • Excludes third-party code (Qt, GoogleTest, system headers)
  • HTML reports generated for detailed analysis
  • Coverage metrics tracked in CI pipeline

✨ Features

  • πŸ“ Registration Management: Add, view, and manage different types of registrations (Standard, Student, Guest)
  • πŸ’° Dynamic Fee Calculation: Automatically calculate registration fees based on type
  • πŸ“Š Attendee Analytics: Real-time display of attendee counts per affiliation
  • πŸ” Smart Filtering: Instantly filter registrations by attendee name with live updates
  • πŸ“€ Export Functionality: Serialize registration data to XML format for backup and transfer
  • πŸ“₯ Import Functionality: Deserialize and append registration data from XML files
  • 🎨 Intuitive UI: Clean, user-friendly Qt-based interface with toolbar and menu access
  • πŸ”„ Cross-Platform: Runs seamlessly on Windows, macOS, and Linux

πŸ“Έ Screenshots

Main Window - Viewing & Filtering Registrations

Registrations can be filtered using any of the fields filtering-registrations

Handling XML

registrations-xml

πŸš€ Getting Started

Prerequisites

Ensure you have the following installed on your system:

  • Qt Framework: Version 5 or 6 (Download Qt)
  • CMake: Version 3.5 or higher (Download CMake)
  • C++ Compiler: C++17 compatible (GCC, Clang, MSVC)

To Build & Run:

  1. Clone the Repository:

    git clone https://github.com/mitchcamza/ConferenceRegistration.git
    cd ConferenceRegistration
  2. Build

    mkdir build && cd build
    cmake -S .. -B .
    cmake --build .   # add "--config Release" for multi-config generators (e.g., Visual Studio, Xcode)
  3. Run the Application

    On Windows (Git Bash/WSL):

    # For multi-config generators (Visual Studio), executables are in config subdirectories:
    ./Release/ConferenceRegistration.exe   # or ./Debug/ConferenceRegistration.exe
    
    # For single-config generators (Ninja, MinGW Makefiles):
    ./ConferenceRegistration.exe

    On Windows (cmd/PowerShell):

    # For multi-config generators (Visual Studio), executables are in config subdirectories:
    .\Release\ConferenceRegistration.exe   # or .\Debug\ConferenceRegistration.exe
    
    # For single-config generators (Ninja, MinGW Makefiles):
    .\ConferenceRegistration.exe

    On Linux:

    chmod +x ConferenceRegistration
    ./ConferenceRegistration

    On macOS:

    # For multi-config generators (Xcode), executables are in config subdirectories:
    # Ensure the bundled executable is runnable (if needed)
    chmod +x Release/ConferenceRegistration.app/Contents/MacOS/ConferenceRegistration
    
    # Launch via Finder
    open Release/ConferenceRegistration.app   # or Debug/ConferenceRegistration.app
    
    # Or run the binary directly
    ./Release/ConferenceRegistration.app/Contents/MacOS/ConferenceRegistration
    
    # For single-config generators (Unix Makefiles, Ninja):
    open ConferenceRegistration.app
    # or ./ConferenceRegistration.app/Contents/MacOS/ConferenceRegistration

⏱️ Build Time: Less than a minute on a modern system.

πŸ“ Project Structure

ConferenceRegistration/
β”œβ”€β”€ CMakeLists.txt                      # CMake build configuration
β”œβ”€β”€ resources/                          # Assets and Qt resource collection
β”‚   β”œβ”€β”€ icons/                          # SVG icons used in the UI
β”‚   └── resources.qrc                   # Qt resource file referencing icons
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ main.cpp                        # Application entry point
β”‚   β”‚
β”‚   β”œβ”€β”€ core_classes
β”‚   β”‚   β”œβ”€β”€ person.h/cpp                # Base Person class
β”‚   β”‚   β”œβ”€β”€ registration.h/cpp          # Abstract Registration base class
β”‚   β”‚   β”œβ”€β”€ standardregistration.*      # Standard registration type
β”‚   β”‚   β”œβ”€β”€ studentregistration.*       # Student registration type
β”‚   β”‚   └── guestregistration.*         # Guest registration type
β”‚   β”‚
β”‚   β”œβ”€β”€ data_management
β”‚   β”‚   β”œβ”€β”€ registrationlist.h/cpp      # Registration collection manager
β”‚   β”‚   β”œβ”€β”€ registrationfactory.*       # Factory pattern for creating registrations
β”‚   β”‚   └── registrationtypes.*         # Registration type enumerations
β”‚   β”‚
β”‚   β”œβ”€β”€ qt_models
β”‚   β”‚   β”œβ”€β”€ registrationmodel.*         # Custom QAbstractTableModel
β”‚   β”‚   └── registrationfilterproxymodel.* # Filter proxy for search
β”‚   β”‚
β”‚   β”œβ”€β”€ ui_components
β”‚   β”‚   β”œβ”€β”€ mainwindow.*                # Main application window
β”‚   β”‚   β”œβ”€β”€ newregistrationdialog.*     # Add registration dialog
β”‚   β”‚   β”œβ”€β”€ totalfeesdialog.*           # Display total fees
β”‚   β”‚   └── totalregistereddialog.*     # Display attendee counts
β”‚   β”‚
β”‚   └── serialization
β”‚       β”œβ”€β”€ filewriter.h/cpp            # Generic file writing
β”‚       β”œβ”€β”€ filereader.h/cpp            # Generic file reading
β”‚       β”œβ”€β”€ registrationlistwriter.*    # XML serialization
β”‚       └── registrationlistreader.*    # XML deserialization
β”‚
β”œβ”€β”€ tests/
β”‚   β”œβ”€β”€ unit/                           # Unit tests (42 tests)
β”‚   β”‚   β”œβ”€β”€ person_test.cpp             # Person class tests
β”‚   β”‚   β”œβ”€β”€ registration_test.cpp       # Registration types tests
β”‚   β”‚   └── registrationfactory_test.cpp # Factory pattern tests
β”‚   β”‚
β”‚   β”œβ”€β”€ integration/                    # Integration tests (16 tests)
β”‚   β”‚   β”œβ”€β”€ xml_persistence_test.cpp    # End-to-end XML I/O tests
β”‚   β”‚   └── README.md                   # Integration test documentation
β”‚   β”‚
β”‚   β”œβ”€β”€ ui/                             # UI tests (3 suites, 38 test functions)
β”‚   β”‚   β”œβ”€β”€ mainwindow_test.cpp         # MainWindow UI tests
β”‚   β”‚   β”œβ”€β”€ newregistrationdialog_test.cpp # Dialog UI tests
β”‚   β”‚   β”œβ”€β”€ statistics_dialogs_test.cpp # Statistics dialogs tests
β”‚   β”‚   └── README.md                   # UI test documentation
β”‚   β”‚
β”‚   └── fixtures/
β”‚       └── xml/                        # Test fixture files
β”‚           β”œβ”€β”€ valid_standard.xml      # Valid test data
β”‚           β”œβ”€β”€ malformed.xml           # Error case fixtures
β”‚           └── README.md               # Fixture documentation
β”‚
└── tools/
   β”œβ”€β”€ build_and_run.sh                # Helper build script
   β”œβ”€β”€ coverage_summary.sh             # Coverage metrics script
   └── registrationgenerator.py        # Utility script for generating registrations

Total Lines of Code: ~3,200 lines across 45+ files

πŸ§ͺ Testing

The project includes a comprehensive test suite to ensure code reliability and correctness. Tests are fast, deterministic, and suitable for CI/CD pipelines, covering unit-level logic, end-to-end integration scenarios, and UI component testing.

Test Coverage

The test suite includes 61 tests covering:

Unit Tests (42 tests)

Using GoogleTest framework:

  • Person Tests (6 tests): Constructor validation, empty/whitespace handling, special characters, and boundary testing
  • Registration Tests (17 tests): Fee calculations for all registration types (Standard: $100, Student: $50, Guest: $10), booking date validation, and toString formatting
  • RegistrationFactory Tests (19 tests): Singleton pattern verification, registration creation, case-insensitive type handling, and edge case validation

Integration Tests (16 tests)

Using GoogleTest framework:

  • Round-trip Integrity (5 tests): Write registrations to XML, read them back, and verify data integrity across all registration types
  • Golden File Fixtures (4 tests): Parse known-good XML files and validate correct deserialization behavior
  • Error & Edge Cases (7 tests): Malformed XML handling, missing required fields, missing type attributes, empty files, non-existent files, read-only locations, and deterministic output verification

UI Tests (3 suites, 38 test functions)

Using Qt Test framework:

  • MainWindow Tests (11 tests): Window initialization, menu structure (File, Edit, Reports), toolbar, table view/model, search widget
  • NewRegistrationDialog Tests (14 tests): Dialog initialization, form fields, validation, registration type switching, conditional field visibility (student qualification, guest category)
  • Statistics Dialogs Tests (13 tests): TotalFeesDialog and TotalRegisteredDialog initialization, calculations, and display

Code Coverage

  • Line Coverage: 81.5% (555 of 681 lines)
  • Function Coverage: 78.8% (78 of 99 functions)
  • Coverage reports generated using lcov/genhtml
  • Excludes third-party code (Qt, GoogleTest, system headers)

Running Tests

Run All Tests

cd build
# Set headless mode for UI tests
export QT_QPA_PLATFORM=offscreen
ctest --output-on-failure

Run Unit Tests Only

cd build/tests/unit
./unit_tests

Run Integration Tests Only

cd build
ctest --output-on-failure -R XmlPersistence

Run UI Tests Only

cd build
export QT_QPA_PLATFORM=offscreen
ctest --output-on-failure -R "MainWindowTests|NewRegistrationDialogTests|StatisticsDialogsTests"

# Or run individually
cd tests/ui
./mainwindow_test
./newregistrationdialog_test
./statistics_dialogs_test

Run Specific Tests

# Unit tests
./unit_tests --gtest_filter=PersonTest.*
./unit_tests --gtest_filter=RegistrationFactoryTest.CreateStandardRegistration*

# Integration tests
cd build/tests/integration
./integration_tests --gtest_filter=XmlPersistenceTest.RoundTripStandardRegistration

Generate Code Coverage Report

# Build with coverage enabled
cmake -S . -B build -DENABLE_COVERAGE=ON
cd build
make

# Run tests
export QT_QPA_PLATFORM=offscreen
ctest --output-on-failure

# Generate coverage report
make coverage

# View coverage summary
../tools/coverage_summary.sh

# View HTML report
xdg-open coverage_report/index.html  # Linux
open coverage_report/index.html      # macOS

CI Integration

Tests run automatically on every pull request via GitHub Actions, ensuring code changes don't introduce regressions. Unit, integration, and UI tests must all pass before merging. Code coverage reports are generated and uploaded as artifacts.

For detailed test documentation, see:

πŸ“– Usage

The application allows users to manage different types of registrations. The main window provides options to view and filter existing registrations, add new registrations and view the total fees and number of registrations.

Adding a Registration

  1. Click on "New Registration"
  2. Fill in the required details (name, email, affiliation, booking date)
  3. Select the type of registration (Standard, Student, or Guest)
  4. Submit the registration

Viewing Total Fees and Registrations

  • Click on "Total Fees" to view the total registration fees
  • Click on "Total Registrations" to view the number of registrations per affiliation

Filtering Registrations

  • Begin typing the first or last name of an attendee in the search bar and the displayed results will update in real-time
  • Clear the filter by removing the text, or using the 'Clear Filter' button

Exporting Registrations

  1. Click on "Export Registrations" in the edit menu or toolbar
  2. Browse to the desired directory using the file dialog and provide a file name
  3. Click on "Save" and the registration list will be saved to file

Note: Selecting an existing file will overwrite its contents.

Importing Registrations

  1. Click on "Import Registrations" in the edit menu or toolbar
  2. Browse for the XML file containing the registration list to be imported
  3. Once the file has been selected, the imported registrations will be appended to the existing registration list

Generating Test Registrations

For testing and demonstration purposes, a Python script is provided to generate sample registration data:

  1. Navigate to the tools directory:

    cd tools
  2. Run the registration generator:

    python3 registrationgenerator.py
  3. Output: The script will create a file named registrationlist.xml in the current directory containing 200 sample registrations with the following distribution:

    • Student registrations: 67 registrations (fee: $50 each)
    • Standard registrations: 67 registrations (fee: $100 each)
    • Guest registrations: 66 registrations (fee: $10 each)
  4. Import the generated file:

    • Launch the Conference Registration application
    • Click "Import Registrations" from the File menu or toolbar
    • Select the generated registrationlist.xml file
    • The 200 test registrations will be appended to your current registration list

Note: The generator creates sample data with placeholder names, emails, and affiliations for testing purposes. Each registration includes all required fields according to its type (qualification for students, category for guests).

πŸ’‘ What I Learned

Building this project provided hands-on experience with several important concepts:

Technical Growth

  • Qt Framework Mastery: Gained deep understanding of Qt's Model/View architecture, signal/slot mechanism, and widget system
  • Design Pattern Implementation: Learned to recognize when and how to apply Factory and Singleton patterns effectively
  • Cross-Platform Development: Understood the challenges and solutions for building applications that work across different operating systems
  • XML Processing: Implemented robust parsing and generation of XML data with proper error handling

Software Engineering Practices

  • Clean Architecture: Practiced separating concerns between UI, business logic, and data layers
  • Code Organization: Structured a medium-sized codebase with 40+ files in a maintainable way
  • Unit Testing: Developed 42 unit tests using GoogleTest to validate individual components in isolation, ensuring each class and method works correctly independently
  • Integration Testing: Created 16 integration tests to verify end-to-end workflows, particularly XML serialization/deserialization with round-trip validation and fixture-based testing
  • UI Testing: Implemented 38 UI test functions using Qt Test framework to validate graphical components, ensuring proper widget initialization, user interactions, and signal/slot connections work correctly in headless mode
  • Code Coverage: Integrated lcov/genhtml to track test coverage, achieving 81.5% line coverage and 78.8% function coverage, with HTML reports for detailed analysis
  • CI/CD Integration: Set up automated build pipelines to catch issues early
  • Documentation: Created comprehensive API documentation using Doxygen

Problem-Solving Skills

  • Memory Management: Handled Qt's parent-child object ownership model and avoided memory leaks
  • Polymorphism in Practice: Implemented abstract base classes with multiple derived types
  • Real-time Data Filtering: Developed efficient filtering without compromising user experience
  • Error Handling: Implemented robust error handling for file operations and user input

πŸš€ Future Enhancements

Potential improvements to demonstrate continuous learning:

  • Database Integration: Replace XML with SQLite for better scalability and querying
  • Export Formats: Support for CSV, JSON, and PDF export
  • Authentication: User login system with different permission levels
  • Email Notifications: Automated confirmation emails upon registration
  • Data Analytics: Charts and graphs showing registration trends over time
  • Internationalization: Multi-language support using Qt's translation system
  • Cloud Sync: Optional cloud backup and synchronization across devices

πŸ“š API Documentation

View Full API Documentation

πŸ‘¨β€πŸ’» About Me

Hi, I'm Mitch Campbell, a software engineer with a passion for building practical, well-architected applications. This project demonstrates my ability to:

  • Design and implement complete applications from scratch
  • Write clean, maintainable, and well-documented code
  • Apply software engineering principles and design patterns
  • Work with modern C++ and popular frameworks like Qt
  • Set up development workflows including build automation and CI/CD

I'm actively seeking junior software engineering or programmer positions where I can contribute to meaningful projects while continuing to grow my skills.

Connect with me:

LinkedIn GitHub

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.


⭐ If you found this project helpful or interesting, please consider starring the repository!

About

Cross-platform C++ desktop app for managing conference registrations with Qt Framework, featuring MVC architecture, XML persistence, and comprehensive test coverage

Topics

Resources

License

Stars

Watchers

Forks

Contributors 3

  •  
  •  
  •