Test My Code exercise server used by e.g. http://mooc.fi/
Ruby HTML JavaScript Shell CSS Java
Latest commit 1b7d284 Jan 18, 2017 @nygrenh nygrenh Fixes to the init script
Permalink
Failed to load latest commit information.
app Small fixes related to organizations and creating courses Jan 2, 2017
bin Added doorkeeper Mar 25, 2016
config Refactor submissionss and its nested end points to use the new routin… Nov 28, 2016
db Change course to be disabled by default Jan 3, 2017
doc More whitespace and better readability in User Manual Aug 16, 2016
ext Upgrade the tmc-sandbox submodule Oct 30, 2016
lib Fixes to the init script Jan 18, 2017
public Enable asset pipeline Dec 10, 2014
script Code style auto-corrections by RuboCop Feb 18, 2015
spec Change course to be disabled by default Jan 3, 2017
test Code style auto-corrections by RuboCop Feb 18, 2015
vendor DateTimePicker for deadlines Aug 4, 2015
.dockerignore Ignore more stuff Sep 22, 2016
.gitignore automatically created manual things back to gitignore Oct 8, 2016
.gitmodules Drop tmc-junit-runner as dependency as the implementation of it is us… Jan 6, 2016
.hound.yml Add .hound.yml Nov 25, 2016
.rspec Initial commit of code by written by students + README + LICENSE. Jul 4, 2011
.rubocop.yml Add .hound.yml Nov 25, 2016
.travis-update-usermanual.sh Fix usermanual build for build requests Mar 23, 2016
.travis.yml Split student usecases and reshard travis Mar 31, 2016
Changelog.md Reflect changes to changelog Jan 29, 2016
Contributing.md Configure RuboCop Feb 18, 2015
Dockerfile Refactor dockerfiles Sep 22, 2016
DockerfileBase Refactor dockerfiles Sep 22, 2016
Gemfile Move swagger schema to resources Nov 28, 2016
Gemfile.lock Change swagger validation method Nov 28, 2016
Installation.md Minor updates and fixes Sep 27, 2016
LICENSE Initial commit of code by written by students + README + LICENSE. Jul 4, 2011
README.markdown Update my username Nov 23, 2016
Rakefile another junit formatter for rsec and jenkins Feb 17, 2013
common.yml Allow running tests in docker containers Aug 16, 2016
config.ru Implemented password reset. Jan 17, 2012
dev-entry.sh Dev env Sep 22, 2016
docker-compose-dev.yml Fix bg tasks Sep 22, 2016
docker-compose-remote-sandbox-dev.yml docker compose file for running dev using remote sandbox, fixed entry… Oct 19, 2016
docker-compose-remote-sandbox-test.yml Added docker file for running tests using remote sandbox Oct 19, 2016
docker-compose.yml Fix random issues with tmc-sandbox Sep 12, 2016
entry.sh docker compose file for running dev using remote sandbox, fixed entry… Oct 19, 2016
rubysudo Improved dev scripts. Feb 1, 2014
setup-travis.sh unset set -v after setup is done Apr 6, 2016

README.markdown

Test My Code server

Test My Code ("TMC") is a tool to automate most of the exercise checking when teaching programming. It runs code submitted by students, gives feedback if tests fail and maintains a scoreboard. This allows for lots of small exercises without the need for course instructors to manually go through all of them.

The system has been used with great success by the University of Helsinki CS Dept. in several elementary programming and data structures courses with hundreds of users.

Usermanual

Automatically built usermanual can be viewed at: http://testmycode-usermanual.github.io

Setup

For setup and startup instructions, please see the installation guide.

Running dev in Docker

Before running dev in docker one needs to do some manual setup:

  • git submodule update --init --recursive
  • rake compile To build neccessary external dependencies.

The dev docker mounts local folder to the image and allows code changes to be visible in real time. Dev environment can be run with docker-compose: docker-compose -f docker-compose-dev.yml up

To run rails migrations etc you may exec those like this: docker exec -it tmcserver_dev_1 rake db:create db:migrate db:seed.

The container name can be checked with docker ps

Running tests in parallel

Tests can be run parallel with docker-compose. This expects you to have functioning docker and docker-compose setup.

For collecting test results from different testruns you need to clone and use this: https://github.com/jamox/remote_rspec_aggregator Basically you wan't to clone the repo and bundle install once and run rackup --host 0.0.0.0 --port 4567 to have it accessible from the testruns running in docker.

Once it's running run all tests by executing env REPORT_URL=<IP OF DOCKER INTERFACE> docker-compose up --build and see test results flowing to rspec test result aggregator.

The test environment builds hermetic images for each testrun by including all source files to the testrun container. Thus we need to use --build (or trust docker to detect changes in directories) to run tests for newest code.

Credits

Current maintainers of the project are

The project started as a Software Engineering Lab project at the University of Helsinki CS Dept. but has since been gradually almost completely rewritten. The original authors of the server component were

  • Patrik Marjanen
  • Jarno Mynttinen
  • Martti Rannanjärvi (mrannanj)
  • Katri Rantanen

Another team wrote a NetBeans plugin for the system.

The course instructor and current maintainer of the project is Martin Pärtel (mpartel). Other closely involved instructors were

  • Matti Luukkainen (mluukkai)
  • Antti Laaksonen
  • Arto Vihavainen
  • Jaakko Kurhila

The system was improved and C language support was added in another SE lab project by

Checkstyle-support was integrated by

License

GPLv2