Giter VIP home page Giter VIP logo

Comments (3)

rlenferink avatar rlenferink commented on July 26, 2024

Comment by Johan:

Potential issues would be:

  • CppUTest is easy to build for an end-user and is typically distributed with the package manager. For gtest+gmock this is not the case and the end-user needs to build and install from source by themselves. Alternatively Celix could bundle the binaries and headers, which would add work on the project side instead of the user side.
  • gmock does not support mocking C functions exactly, there are ways of working around this[0][1] which either introduces extra boilerplate or an extra dependency.

[0] https://github.com/hjagodzinski/C-Mock
[1] https://stackoverflow.com/questions/31989040/can-gmock-be-used-for-stubbing-c-functions

from celix.

PengZheng avatar PengZheng commented on July 26, 2024

CppUTest is easy to build for an end-user and is typically distributed with the package manager. For gtest+gmock this is not the case and the end-user needs to build and install from source by themselves. Alternatively Celix could bundle the binaries and headers, which would add work on the project side instead of the user side.

With Conan package manager, one extra line like self.test_requires("gtest/1.10.0") will make gtest ready to use.

Mocking C functions is indeed an issue.

from celix.

PengZheng avatar PengZheng commented on July 26, 2024

This has been addressed by #711.

from celix.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.