Skip to content
Implementing some of Ruby's methods for use in C
C Other
  1. C 99.1%
  2. Other 0.9%
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
docs
scripts
src
test
vendor/ceedling
.gitignore
Doxyfile
LICENSE
LICENSE.bstrlib.txt
Makefile
README.md
project.yml

README.md

Ruby-like C

A library functions that behave more or less like their Ruby counterparts.

The unit tests have all their expected outputs generated by calls to the Ruby methods that the C functions are based on so that whatever value you'd get in Ruby you should also get with these C functions.

Uses the Better String Library internally.

Documentation

Doxygen API docs here.

Development

Clone the repository.

$ git clone https://github.com/mooreryan/ruby_like_c.git

Make some dirs.

$ cd ruby_like_c && mkdir bin test/support

Install ceedling.

$ gem install ceedling

Testing

We use ceedling to run the unit tests. It's snazzy.

Most of the unit tests are based on those for the Ruby source code, e.g., these.

Because we want the functions to give the same values as their Ruby counterparts, some of the tests files should generated automatically like so:

$ ruby scripts/generate_tests.rb

This should dump some files in the test directory.

Then you can run the test suite with the ceedling command.

You can’t perform that action at this time.