Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Exploration of class vs. instance methods via Election Result data using Rails 7 and Ruby 3. For use in Backend Mod 2

NotificationsYou must be signed in to change notification settings

turingschool-examples/election

Repository files navigation

Overview

A repository with information from the 2016 election pulled fromthis Kaggle dataset.

Your job is to fix the failing tests in this application by writing new methods to fit the needs outlined in the model specs. Some of the methods will be class methods, while others will be instance methods.

Setup

$ bundle install$ rails db:{create,migrate,seed}

NOTE! There are about 24,000 primary results that will be imported when you run theseed command. This may take a few minutes to complete. Watch your Terminal for the running output.

Test Suite

There is an existing test suite with some model tests already implemented. Run this suite with:

bundleexec rspec

We recommend that you attempt to resolve the failing specs in the following order:

  • County
  • PrimaryResult
  • Candidate

When you begin, start with

bundleexec rspec spec/models/county_spec.rb

Let the errors in each test guide your implementation.

Solutions

When you are finished, you may opt to compare your answers to oursolutions branch in your browser.

About

Exploration of class vs. instance methods via Election Result data using Rails 7 and Ruby 3. For use in Backend Mod 2

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp