Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6050615
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T07:42:30+00:00 2026-05-23T07:42:30+00:00

I have a mock module where I’d like to pass through certain function calls

  • 0

I have a mock module where I’d like to pass through certain function calls to the original, but the mock module hides the original. Can I call the original by path somehow, or is there a way around this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T07:42:31+00:00Added an answer on May 23, 2026 at 7:42 am

    You can use Meck, a mocking library for Erlang, to achieve this:

    With meck you can easily mock modules
    in Erlang. Since meck is intended to
    be used in testing, you can also
    perform some basic validations on the
    mocked modules, such as making sure no
    function is called in a way it should
    not.

    meck automatically renames existing
    modules in case they are loaded when
    you want to mock them, and restores
    them upon unloading of the mocked
    module. It is also possible to call
    the original functions from a mocked
    module using meck:passthrough/1 from
    inside an expectation.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I got a function in a certain module that I want to redefine(mock) at
I have a basic understanding of mock and fake objects, but I'm not sure
I have a unit test that creates a mock calls my method to be
I'm new to mock objects, but I understand that I need to have my
Say I have a module with the following: def main(): pass if __name__ ==
I have a mock being created like this: var mock = new Mock<IPacket>(MockBehavior.Strict); mock.Setup(p
in fact I have a mock object based on the interface. I would like
I'm working on a media library mock-up and I have a database of songs
I am trying to mock java.awt.Toolkit.beep() using JMockit Expectations. I have the following code
I need to mock a GrailsControllerClass interface. Instance should have a static variable defined.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.