Code Monkey home page Code Monkey logo

Comments (5)

vadiminshakov avatar vadiminshakov commented on August 17, 2024

Yes, it's because of MockStub: https://github.com/hyperledger/fabric/blob/release-1.4/core/chaincode/shim/mockstub.go#L290

from cckit.

r3code avatar r3code commented on August 17, 2024

@vadiminshakov Thanks! I'll use a real network then for such tests.

from cckit.

akoita avatar akoita commented on August 17, 2024

Hi,

After having noticed the limitations of the mock which is in the Fabric source code, I came across CCKit which offers a mock with more possibilities and especially an advanced testing approach with Ginkgo and Gomega.

But I notice that an essential operation like the simulation of CouchDB requests is not supported. Do you plan to add this feature? How else do you test the operations of your chaincodes that execute CouchDB queries?

For information, this other implementation of the chaincode stub in TypesScript provides support for testing CouchDB requests: https://github.com/wearetheledger/fabric-mock-stub.

from cckit.

vitiko avatar vitiko commented on August 17, 2024

Hi, at the moment we don't have plans to add a simulation of CouchDB requests, cause we mostly use encrypted protobuf marshaling to bytes and rich queries can't work with encrypted data. But you can try to do it for the case of JSON data modeling and add pull requests.

from cckit.

akoita avatar akoita commented on August 17, 2024

Hi,
All right, I understand.
For now, I don't plan to implement the simulation of CouchDB requests either, but it would be a pleasure to submit a PR if I happen to implement it.

from cckit.

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.