Cucumber and C/C++ in embedded systems

1,514 views
Skip to first unread message

Massimo Manca

unread,
May 9, 2012, 2:20:44 AM5/9/12
to cu...@googlegroups.com
Hi all,
I like very much gherkin and Cucumber, I would know if someone tried to
use Cucumber to drive the development of embedded applications written
in C and C++ and if possible if there is a plugin or some other tool
that may help to do the job.

Regards,

aslak hellesoy

unread,
May 9, 2012, 2:25:40 AM5/9/12
to cu...@googlegroups.com, Paolo Ambrosio
Not sure about embedded, but there is https://github.com/paoloambrosio/cukebins

I recently spoke to the author, Paolo Ambrosio who have agreed to move
it under the Cucumber organisation om GitHub. That should be happening
soon.

Aslak

> Regards,
>
> -- There are two rules:
>
> 1) Please prefix the subject with [Ruby], [JVM] or [JS]. This allows people to filter messages.
> 2) Please use interleaved answers http://en.wikipedia.org/wiki/Posting_style#Interleaved_style
>
> You received this message because you are subscribed to the Google Groups Cukes group. To post to this group, send email to cu...@googlegroups.com. To unsubscribe from this group, send email to cukes+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/cukes?hl=en

Anthony Green

unread,
May 9, 2012, 6:26:23 AM5/9/12
to cu...@googlegroups.com

In hiss book Matt chooses to use the ChildProcess gem to kick spawn a
process that should run cross-platform.

Has anyone got experience of using this gem got it to work on Windows?
Googling has proved fruitless

Ta

--
Anthony Green
Media Playout
BBC Future Media



http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.

Paolo Ambrosio

unread,
May 9, 2012, 2:44:39 PM5/9/12
to cu...@googlegroups.com
On Wed, May 9, 2012 at 8:20 AM, Massimo Manca
<massimo....@gmail.com> wrote:

> I would know if someone tried to use Cucumber to drive the
> development of embedded applications written
> in C and C++ and if possible if there is a plugin or some other tool
> that may help to do the job.

Hi Massimo,

I'm the author of CukeBins. As Aslak wrote, soon it is going to move
under the Cucumber organisation and change its name to Cucumber-C++ to
match the name of the other projects.

I am not aware of anyone using it to test embedded systems, but if you
feel like testing a C implementation with C++ test code, it should
work.

CukeBins has most of the features that you will need. A notable one
not already implemented is table diffing:

https://github.com/paoloambrosio/cukebins/issues/28

You can get your feet wet with it by reading the short introduction to
the 0.2 release on GitHub:

https://github.com/paoloambrosio/cukebins/wiki/Release-0.2

It comes also with a few small samples in the source "example" directory.

I know the code needs some care, and I am spending my weekends working
to make it cleaner, so that it would be easier for other people to
contribute to the project. The feature I'm spending most of my time is
this one:

https://github.com/paoloambrosio/cukebins/issues/31

We might get rid of the wire protocol at some point but for now I
think it's best to focus on something else. Running the Ruby
implementation of Cucumber should not be a problem.

Let me know if you have questions and I'll try to help.

--
Paolo

Rob Hunter

unread,
May 13, 2012, 1:27:00 PM5/13/12
to cu...@googlegroups.com
On 9 May 2012 05:26, Anthony Green <Anthon...@bbc.co.uk> wrote:
>
> In hiss book Matt chooses to use the ChildProcess gem to kick spawn a
> process that should run cross-platform.
>
> Has anyone got experience of using this gem got it to work on Windows?
> Googling has proved fruitless

I don't have personal experience with the gem but the ChildProcess
README indicates that Windows is absolutely one of the supported
platforms. <https://github.com/jarib/childprocess#implementation>

There's an open issue with the particular combination of JRuby and
64-bit Windows: <https://github.com/jarib/childprocess/issues/26>


--
Rob Hunter

Luis Lavena

unread,
May 13, 2012, 3:28:24 PM5/13/12
to cu...@googlegroups.com
On Wed, May 9, 2012 at 7:26 AM, Anthony Green <Anthon...@bbc.co.uk> wrote:
>
> In hiss book Matt chooses to use the ChildProcess gem to kick spawn a
> process that should run cross-platform.
>
> Has anyone got experience of using this gem got it to work on Windows?
> Googling has proved fruitless
>

ChildProcess does work and works properly on Windows either under
RubyInstaller (matz Ruby implementation) or JRuby.

In both cases it uses the FFI interface to use Windows native functionality.

I personally did notice some "overhead" by depending on FFI and
ChildProcess for some particular functions in one of my programs.

Since this particular program was Ruby 1.9.3 only, I decided to fall
back to Process.spawn which has provided almost similar ChildProcess
functionality without the extra dependencies.

This has been tested in my case in both Linux (Ubuntu 12.04) and
Windows (7 x64 with 32bits Ruby).

I believe by using Aruba will use ChildProcess.

Cheers,
--
Luis Lavena
AREA 17
-
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry

Matt Wynne

unread,
May 14, 2012, 12:31:30 AM5/14/12
to cu...@googlegroups.com
On 9 May 2012, at 13:26, Anthony Green wrote:


In hiss book Matt chooses to use the ChildProcess gem to kick spawn a
process that should run cross-platform.

Has anyone got experience of using this gem got it to work on Windows?
Googling has proved fruitless

Yes, everything in the book works on Windows unless otherwise stated.


Ta

--
Anthony Green
Media Playout
BBC Future Media



http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.


-- There are two rules:

1) Please prefix the subject with [Ruby], [JVM] or [JS]. This allows people to filter messages.
2) Please use interleaved answers http://en.wikipedia.org/wiki/Posting_style#Interleaved_style

You received this message because you are subscribed to the Google Groups Cukes group. To post to this group, send email to cu...@googlegroups.com. To unsubscribe from this group, send email to cukes+un...@googlegroups.com. For more options, visit this group at https://groups.google.com/d/forum/cukes?hl=en

cheers,
Matt


Anthony Green

unread,
Jun 18, 2012, 5:05:11 PM6/18/12
to cu...@googlegroups.com

ChildProcess does work and works properly on Windows either under
RubyInstaller (matz Ruby implementation) or JRuby.

In both cases it uses the FFI interface to use Windows native functionality.

After numerous attempts I still haven't been able to get this to work.
It seems there have been and remain a number of issues with FFI on Windows and I think this the most likely cause.
Since I'm using Ruby 1.9.3 on both platforms I'm going to investigate Process.spawn as an alternative.

Thanks for your help

Tony

Anthony Green

unread,
Oct 14, 2012, 5:49:00 AM10/14/12
to cu...@googlegroups.com


On Wednesday, 9 May 2012 11:26:23 UTC+1, Anthony Green wrote:

In hiss book Matt chooses to use the ChildProcess gem to kick spawn a
process that should run cross-platform.

Has anyone got experience of using this gem got it to work on Windows?
Googling has proved fruitless                         

So I believe it's now recognised there is indeed a problem with childprocess 


The solution that worked for me is documented in the post

ChildProcess.build("ruby", "-S", "rackup", "--port", "9999")

Hope this helps the next person to Google for this issue.

Best

Tony

Itamar Hassin

unread,
Jan 8, 2016, 9:40:06 PM1/8/16
to Cukes
Reply all
Reply to author
Forward
0 new messages