Giter Site home page Giter Site logo

Comments (11)

mlafeldt avatar mlafeldt commented on May 16, 2024

Emma, don't waste your time evaluating test frameworks. We "democratically" decided to go with Sharness -- see #18. 🔨

from netsniff-ng.

eroullit avatar eroullit commented on May 16, 2024

I am still convinced Ctest covers some ground Shareness does not and vice-versa.
When such "democracy" occurs, people say: ¡No Pasarán! ✊

from netsniff-ng.

mlafeldt avatar mlafeldt commented on May 16, 2024

Yeah, Ctest is better suited for C unit testing. Sharness prevails when it comes to testing command-line interfaces or shell code itself. So we really have two distinct use cases and it's not black and white.

from netsniff-ng.

eroullit avatar eroullit commented on May 16, 2024

In the end, looks more like an unanimity.

(Quote from yesterday's IM on the topic)

Daniel: mathias agreed to include his shareness improvements with some basic test bases into netsniiff-ng
Me: yes I saw the ticket and its answer. we will see, but I can already tell you that it is not a silver bullet (e.g. specific function test)
Daniel: okay
Me: but I think ctest and shareness would make a very good combo
Daniel: yes, i think so too
Me: as ctest misses on higher level tests
Daniel: yes, exactly, that's where shareness comes in
Me: in a nutsheel ctest for low-level test and shareness for high-level ones
Daniel: yes, fully ack

from netsniff-ng.

mlafeldt avatar mlafeldt commented on May 16, 2024

No matter what framework we're using, it looks like netsniff-ng always needs root privileges, which is obviously bad for automated testing.

from netsniff-ng.

borkmann avatar borkmann commented on May 16, 2024

Maybe there are some hacks for rules.d about which I am not yet aware of. It should definitly be possible to run curvetun, for instance, without root privileges.

from netsniff-ng.

borkmann avatar borkmann commented on May 16, 2024

FYI: I just closed issue 12 (http://coccinelle.lip6.fr/) and would like to move the discussion to this ticket, so that we have all 3 frameworks here.

Semantic patches should go into: src/s/
Sharness + Ctest should go into: src/t/

from netsniff-ng.

mlafeldt avatar mlafeldt commented on May 16, 2024

So you even need to be root to let netsniff-ng process a .pcap?

Keep in mind that using Sharness (or any scripts) as root could backfire very easily.

from netsniff-ng.

borkmann avatar borkmann commented on May 16, 2024

How exactly do you define "backfire"? Most likely, you need to run those tools (except ifpps, curvetun [with rules.d adaption]) as root. For instance, in netsniff-ng you have RX/TX_RINGs. Only root can allocate them.

from netsniff-ng.

mlafeldt avatar mlafeldt commented on May 16, 2024

It was late and I worried about running all tests via root. But I guess it'd be okay to say sudo netsniff-ng to limit privileges to particular commands. (Need to test how Sharness copes with that.)

And btw: http://www.dict.cc/?s=backfire :)

from netsniff-ng.

borkmann avatar borkmann commented on May 16, 2024

Included in PROJECTS file.

from netsniff-ng.

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.