{"id":25790475,"url":"https://github.com/hpi-epic/profci-exercise","last_synced_at":"2025-02-27T12:07:08.433Z","repository":{"id":15778498,"uuid":"78749606","full_name":"hpi-epic/profci-exercise","owner":"hpi-epic","description":"Employing Continuous Integration Services and Github Workflows to Teach Test-driven Development","archived":false,"fork":false,"pushed_at":"2022-12-14T02:11:04.000Z","size":1216,"stargazers_count":7,"open_issues_count":7,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-21T03:12:43.860Z","etag":null,"topics":["automation","exercise","ruby","student-centered","tdd","teaching","travis-ci","tutorial"],"latest_commit_sha":null,"homepage":"https://hpi-epic.github.io/profci-exercise/","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hpi-epic.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-01-12T13:45:28.000Z","updated_at":"2022-01-08T03:32:05.000Z","dependencies_parsed_at":"2023-01-11T20:23:57.522Z","dependency_job_id":null,"html_url":"https://github.com/hpi-epic/profci-exercise","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hpi-epic%2Fprofci-exercise","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hpi-epic%2Fprofci-exercise/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hpi-epic%2Fprofci-exercise/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hpi-epic%2Fprofci-exercise/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hpi-epic","download_url":"https://codeload.github.com/hpi-epic/profci-exercise/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241010210,"owners_count":19893501,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["automation","exercise","ruby","student-centered","tdd","teaching","travis-ci","tutorial"],"created_at":"2025-02-27T12:07:07.782Z","updated_at":"2025-02-27T12:07:08.424Z","avatar_url":"https://github.com/hpi-epic.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Prof. CI -- Ruby on Rails and TDD exercise\n\nWe prepared an application skeleton for you that has a failing test case.\n\nTo pass the exercise, follow these steps:\n\n## 1) Fork this repository.\n\n* You need to be logged-in with your Github account.\n* Click the \"Fork\" button in the upper right. \n\n![fork](https://cloud.githubusercontent.com/assets/1652117/19190800/ce8e6a42-8c9f-11e6-8047-60a238fcd200.png)\n* In your [repository's settings](/../../settings), enable issue tracking.\n\n![issues](https://cloud.githubusercontent.com/assets/1652117/19190926/65ee376e-8ca0-11e6-8755-5e67eaf37cab.png)\n\n## 2) Set-up Travis CI for your fork\n\n* Log-in to [Travis CI](http://travis-ci.org) and\n* Enable automatic builds for your exercise repository.\n\n## 3) Setup development environment\n\n* Clone the repository to your local machine\n\n### Option 1: Setup locally\n* Change into the newly created directoy\n* Inside the directory, check the used Ruby version using `ruby --version`. It should be `2.2.2`. Other Ruby versions might work, but this is the one that was tested.\n* If the correct Ruby version is not used, install a ruby version manager, for example [rbenv](https://github.com/rbenv/rbenv) using the instructions for [rbenv installation](https://github.com/rbenv/rbenv#basic-github-checkout) and [ruby-build installation](https://github.com/rbenv/ruby-build#installing-as-an-rbenv-plugin-recommended).\n  * WARNING: If you already have the Ruby version manager [RVM](https://rvm.io/) installed, please use that or uninstall it prior to rbenv installation, as the two version managers are incompatible.\n* Install Ruby version 2.2.2 with `rbenv install 2.2.2`\n* The `.ruby_version` file in the repository instructs the ruby version manager to use the correct version.\n\n### Option 2: Use a VM\n* Install [Virtualbox](https://www.virtualbox.org/manual/ch02.html) (the VM provider) and [Vagrant](https://www.vagrantup.com/docs/installation/) (to manage VMs) for your platform.\n* Download the prepared VM image and install the dependencies:\n\n```\nvagrant up # download the image and start the VM\nvagrant ssh # connect via ssh\ncd hpi-swt2\nbundle install # install dependencies\nexit # restarting the session for changes to take effect\n```\n* In order to start the development server:\n\n```\nvagrant ssh #connect with VM\ncd hpi-swt2\nrails s -b 0 #starting rails server, the -b part is necessary since the app is running in a VM and would otherwise drop the requests coming from the host OS\n```\n\n* Edits to files in the local folder will be mirrored into the VM's `hpi-swt2` folder as the folders are synced.\n\n## 4) Dive into the code\n\n* Run `bundle install` to install the dependencies of the project (they are stored in the `Gemfile`)\n* Run `rspec` to run the tests ([RSpec](http://rspec.info/) is a test framework for Ruby)\n* Try to get the failing test green.\n\n## 5) Commit and push\n\n* When you are done, push your changes.\n* Travis CI will now try to build your project.\n\n## 6) Check your inbox\n\n* You will be notified of problems via Github issues.\n* While you wait, see if your code can use some refactorings, continue reading the tutorial, or plan the next steps.\n\n## 7) For each ticket\n\n* Write a test that documents the missing or failing behavior.\n  * Unit tests are preferred.\n* Commit the failing test and reference the issue.\n  * The commit message could be `Failing test for #\u003cISSUE NUMBER\u003e`.\n  * There is no need to push the failing commit.\n* Fix the issue and commit all changes.\n  * The commit message could be `\u003cCHANGED THE THING\u003e. Closes #\u003cISSUE NUMBER\u003e`.\n\n## 8) Repeat steps 5 to 7 until the exercise is complete.\n\nTips:\n\n* This exercise is designed to be solved while reading the official [Rails tutorial](http://guides.rubyonrails.org/getting_started.html)\n* run `rspec spec/\u003cpath_to_spec\u003e.rb` to only run one set of specs\n* have a look at `/spec/factories` to get 'inspiration' for your data model\n* Besides simple scaffolds, [associations](http://guides.rubyonrails.org/association_basics.html) and [validations](http://guides.rubyonrails.org/active_record_validations.html) are needed ...\n* occasionally start up the server (`rails s`) and have a look at the app in your browser (`http://localhost:3000`)\n* Look at the Mockup: https://gomockingbird.com/mockingbird/index.html?project=v890g6l#v890g6l/OQMURm\n* Make sure that all local changes are committed (`git status`) and pushed to the upstream repository (i.e., the one on GitHub) before the deadline\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhpi-epic%2Fprofci-exercise","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhpi-epic%2Fprofci-exercise","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhpi-epic%2Fprofci-exercise/lists"}