Commit 6cebb90

mo khan <mo@mokhan.ca>
2015-05-19 06:01:03
remove items.
1 parent eeb9799
app/assets/javascripts/models/calculator.js.coffee
@@ -1,3 +1,3 @@
-class SupplyCrow.Calculator
+class StrongLifters.Calculator
   add: (x, y) ->
     x + y
app/assets/javascripts/application.js
@@ -17,4 +17,4 @@
 //= require_self
 //= require_tree .
 
-var SupplyCrow = SupplyCrow || {};
+var StrongLifters = StrongLifters || {};
app/assets/javascripts/items.js
@@ -1,10 +0,0 @@
-$(function(){
-  $(".delete_stub").click(function(){
-    $(this).hide();
-    $(".delete_form").show();
-  });
-  $(".delete_form .cancel").click(function(){
-    $(this).parent("form").hide();
-    $(".delete_stub").show();
-  });
-});
app/controllers/items_controller.rb
@@ -1,51 +0,0 @@
-class ItemsController < ApplicationController
-  def index
-    @items = current_user.items
-    @item = Item.new
-  end
-
-  def show
-    @item = current_user.items.find(params[:id])
-  end
-
-  def new
-    @item = params[:item].present? ? Item.new(secure_params) : Item.new
-  end
-
-  def edit
-    @item = current_user.items.find(params[:id])
-  end
-
-  def create
-    @item = current_user.items.build(secure_params)
-    if @item.save
-      redirect_to dashboard_path
-    else
-      flash[:warning] = @item.errors.full_messages
-      render :new
-    end
-  end
-
-  def update
-    item = current_user.items.find(params[:id])
-    item.update!(secure_params)
-    redirect_to dashboard_path
-  end
-
-  def destroy
-    current_user.items.destroy(params[:id])
-    redirect_to dashboard_path
-  end
-
-  private
-
-  def secure_params
-    params.require(:item).permit(
-      :name,
-      :description,
-      :serial_number,
-      :purchase_price,
-      :purchased_at,
-    )
-  end
-end
app/mailers/user_mailer.rb
@@ -1,6 +1,6 @@
 class UserMailer < ApplicationMailer
   def registration_email(user)
     @username = user.username
-    mail to: user.email, subject: "Welcome to Supply Crow."
+    mail to: user.email, subject: "Welcome to Strong Lifters."
   end
 end
app/models/item.rb
@@ -1,6 +0,0 @@
-class Item < ActiveRecord::Base
-  belongs_to :user
-
-  validates :user, presence: true
-  validates :name, presence: true
-end
app/models/user.rb
@@ -1,6 +1,5 @@
 class User < ActiveRecord::Base
   has_secure_password
-  has_many :items
   USERNAME_REGEX=/\A[-a-z0-9_.]*\z/i
 
   validates :username, presence: true, format: { with: USERNAME_REGEX }, uniqueness: true
app/views/items/_form.html.erb
@@ -1,31 +0,0 @@
-<%= form_for(@item) do |f| %>
-  <div class="small-12 columns">
-    <%= f.label :name, t('.name') %>
-    <%= f.text_field :name %>
-  </div>
-  <div class="small-12 columns">
-    <%= f.label :description, t('.description') %>
-    <%= f.text_area :description %>
-  </div>
-  <div class="small-12 columns">
-    <%= f.label :serial_number, t('.serial_number') %>
-    <%= f.text_field :serial_number %>
-  </div>
-  <div class="small-12 columns">
-    <div class="row">
-      <div class="small-6 columns">
-        <%= f.label :purchase_price, t('.purchase_price') %>
-        <%= f.text_field :purchase_price %>
-      </div>
-      <div class="small-6 columns">
-        <%= f.label :purchased_at, t('.purchase_date') do %>
-          <%=  t('.purchased_at') %>
-          <%= f.date_field :purchased_at %>
-        <% end %>
-      </div>
-    </div>
-  </div>
-  <div class="small-12 columns">
-    <%= f.submit t('.create_button'), class: 'button' %>
-  </div>
-<% end %>
app/views/items/edit.html.erb
@@ -1,6 +0,0 @@
-<h1>Editing Item</h1>
-
-<%= render 'form' %>
-
-<%= link_to 'Show', @item %> |
-<%= link_to 'Back', items_path %>
app/views/items/index.html.erb
@@ -1,51 +0,0 @@
-<div class="row">
-  <!-- Side Bar -->
-  <div class="large-4 small-12 columns">
-    <div class="hide-for-small panel">
-      <div class="row">
-        <%= form_for(@item, url: new_item_path, method: :get) do |f| %>
-          <div class="small-12 columns">
-            <label><%= t('.item_name') %>
-              <%= f.text_field :name %>
-            </label>
-          </div> <!-- /.small-12 -->
-          <div class="small-12 columns">
-            <%= f.submit t('.new_item_button'), class: 'button' %>
-          </div> <!-- /.small-12 -->
-        <% end %>
-      </div>
-    </div>
-
-    <a href="#">
-      <div class="panel callout radius">
-        <h6>99ย  items in your cart</h6>
-      </div>
-    </a>
-  </div>
-  <!-- End Side Bar -->
-
-  <!-- Thumbnails -->
-  <div class="large-8 columns">
-    <div class="row">
-      <% if @items.any? %>
-        <% @items.each do |item| %>
-          <div class="large-4 small-6 columns">
-            <img src="http://placehold.it/1000x1000&text=Thumbnail">
-
-            <div class="panel">
-              <h5><%= link_to item.name, item_path(item) %></h5>
-              <h6 class="subheader"><%= number_to_currency item.purchase_price %></h6>
-            </div>
-          </div>
-        <% end %>
-      <% else %>
-        <div class="small-12 columns">
-          <h1>Your inventory is empty</h1>
-          <%= link_to 'New Item', new_item_path %>
-        </div>
-      <% end %>
-    </div>
-    <!-- End Thumbnails -->
-    </div>
-  </div>
-</div>
app/views/items/new.html.erb
@@ -1,7 +0,0 @@
-<div class="row">
-  <div class="small-12 columns">
-    <h1>New Item</h1>
-  </div>
-
-  <%= render 'form' %>
-</div>
app/views/items/show.html.erb
@@ -1,33 +0,0 @@
-<p id="notice"><%= notice %></p>
-
-<p>
-  <strong>Name:</strong>
-  <%= @item.name %>
-</p>
-
-<p>
-  <strong>Description:</strong>
-  <%= @item.description %>
-</p>
-
-<p>
-  <strong>Serial number:</strong>
-  <%= @item.serial_number %>
-</p>
-
-<p>
-  <strong>Purchase price:</strong>
-  <%= @item.purchase_price %>
-</p>
-
-<p>
-  <strong>Purchased at:</strong>
-  <%= @item.purchased_at %>
-</p>
-
-<%= link_to t(".edit_button"), edit_item_path(@item) %>
-<button class="small delete_stub"><%= t(".delete_button")%></button>
-<%= form_for @item, method: :delete, html: { class: "delete_form" } do |f| %>
-  <%= f.submit t(".delete_confirm"), class: "small alert button" %>
-  <button class="small secondary button cancel" type="button"><%= t(".cancel_button")%></button>
-<% end %>
app/views/layouts/_terms_content.html.erb
@@ -14,19 +14,19 @@
 <ol type="a">
 	<li>
 		Permission is granted to temporarily download one copy of the materials 
-		(information or software) on Supply Crow's web site for personal, 
+		(information or software) on Strong Lifters web site for personal, 
 		non-commercial transitory viewing only. This is the grant of a license, 
 		not a transfer of title, and under this license you may not:
 		<ol type="i">
 			<li>modify or copy the materials;</li>
 			<li>use the materials for any commercial purpose, or for any public display (commercial or non-commercial);</li>
-			<li>attempt to decompile or reverse engineer any software contained on Supply Crow's web site;</li>
+			<li>attempt to decompile or reverse engineer any software contained on Strong Lifters web site;</li>
 			<li>remove any copyright or other proprietary notations from the materials; or</li>
 			<li>transfer the materials to another person or "mirror" the materials on any other server.</li>
 		</ol>
 	</li>
 	<li>
-		This license shall automatically terminate if you violate any of these restrictions and may be terminated by Supply Crow at any time. Upon terminating your viewing of these materials or upon the termination of this license, you must destroy any downloaded materials in your possession whether in electronic or printed format.
+		This license shall automatically terminate if you violate any of these restrictions and may be terminated by Strong Lifters at any time. Upon terminating your viewing of these materials or upon the termination of this license, you must destroy any downloaded materials in your possession whether in electronic or printed format.
 	</li>
 </ol>
 <h3>
@@ -34,38 +34,38 @@
 </h3>
 <ol type="a">
 	<li>
-		The materials on Supply Crow's web site are provided "as is". Supply Crow makes no warranties, expressed or implied, and hereby disclaims and negates all other warranties, including without limitation, implied warranties or conditions of merchantability, fitness for a particular purpose, or non-infringement of intellectual property or other violation of rights. Further, Supply Crow does not warrant or make any representations concerning the accuracy, likely results, or reliability of the use of the materials on its Internet web site or otherwise relating to such materials or on any sites linked to this site.
+		The materials on Strong Lifters web site are provided "as is". Strong Lifters makes no warranties, expressed or implied, and hereby disclaims and negates all other warranties, including without limitation, implied warranties or conditions of merchantability, fitness for a particular purpose, or non-infringement of intellectual property or other violation of rights. Further, Strong Lifters does not warrant or make any representations concerning the accuracy, likely results, or reliability of the use of the materials on its Internet web site or otherwise relating to such materials or on any sites linked to this site.
 	</li>
 </ol>
 <h3>
 	4. Limitations
 </h3>
 <p>
-	In no event shall Supply Crow or its suppliers be liable for any damages (including, without limitation, damages for loss of data or profit, or due to business interruption,) arising out of the use or inability to use the materials on Supply Crow's Internet site, even if Supply Crow or a Supply Crow authorized representative has been notified orally or in writing of the possibility of such damage. Because some jurisdictions do not allow limitations on implied warranties, or limitations of liability for consequential or incidental damages, these limitations may not apply to you.
+	In no event shall Strong Lifters or its suppliers be liable for any damages (including, without limitation, damages for loss of data or profit, or due to business interruption,) arising out of the use or inability to use the materials on Strong Lifters Internet site, even if Strong Lifter or a Strong Lifter authorized representative has been notified orally or in writing of the possibility of such damage. Because some jurisdictions do not allow limitations on implied warranties, or limitations of liability for consequential or incidental damages, these limitations may not apply to you.
 </p>
 <h3>
 	5. Revisions and Errata
 </h3>
 <p>
-	The materials appearing on Supply Crow's web site could include technical, typographical, or photographic errors. Supply Crow does not warrant that any of the materials on its web site are accurate, complete, or current. Supply Crow may make changes to the materials contained on its web site at any time without notice. Supply Crow does not, however, make any commitment to update the materials.
+	The materials appearing on Strong Lifters web site could include technical, typographical, or photographic errors. Strong Lifters does not warrant that any of the materials on its web site are accurate, complete, or current. Strong Lifters may make changes to the materials contained on its web site at any time without notice. Strong Lifters does not, however, make any commitment to update the materials.
 </p>
 <h3>
 	6. Links
 </h3>
 <p>
-	Supply Crow has not reviewed all of the sites linked to its Internet web site and is not responsible for the contents of any such linked site. The inclusion of any link does not imply endorsement by Supply Crow of the site. Use of any such linked web site is at the user's own risk.
+	Strong Lifters has not reviewed all of the sites linked to its Internet web site and is not responsible for the contents of any such linked site. The inclusion of any link does not imply endorsement by Strong Lifters of the site. Use of any such linked web site is at the user's own risk.
 </p>
 <h3>
 	7. Site Terms of Use Modifications
 </h3>
 <p>
-	Supply Crow may revise these terms of use for its web site at any time without notice. By using this web site you are agreeing to be bound by the then current version of these Terms and Conditions of Use.
+	Strong Lifters may revise these terms of use for its web site at any time without notice. By using this web site you are agreeing to be bound by the then current version of these Terms and Conditions of Use.
 </p>
 <h3>
 	8. Governing Law
 </h3>
 <p>
-	Any claim relating to Supply Crow's web site shall be governed by the laws of the State of Alberta without regard to its conflict of law provisions.
+	Any claim relating to Strong Lifters's web site shall be governed by the laws of the State of Alberta without regard to its conflict of law provisions.
 </p>
 <p>
 	General Terms and Conditions applicable to Use of a Web Site.
@@ -101,4 +101,4 @@
 </ul>
 <p>
 	We are committed to conducting our business in accordance with these principles in order to ensure that the confidentiality of personal information is protected and maintained. 
-</p>
\ No newline at end of file
+</p>
app/views/layouts/application.html.erb
@@ -12,11 +12,9 @@
     <%= render partial: 'layouts/flash' %>
     <div class="row">
       <div class="large-12 columns">
-   
       <!-- Navigation -->
         <div class="row">
           <div class="large-12 columns">
-   
             <nav class="top-bar" data-topbar>
               <ul class="title-area">
                 <!-- Title Area -->
@@ -24,11 +22,10 @@
                   <svg viewBox="0 0 82.515 266.693">
                     <use xlink:href="<%= asset_path "sprite.svg#feather" %>"></use>
                   </svg>
-                  <h1><%= link_to "Supply Crow", dashboard_path %></h1>
+                  <h1><%= link_to "Strong Lifters", dashboard_path %></h1>
                 </li>
                 <li class="toggle-topbar menu-icon"><a href="#"><span>menu</span></a></li>
               </ul>
-           
               <section class="top-bar-section">
                 <!-- Right Nav Section -->
                 <ul class="right">
@@ -80,21 +77,15 @@
             <!-- End Top Bar -->
           </div>
         </div>
-   
       <!-- End Navigation -->
-   
       <%= yield %>
-   
       <!-- Footer -->
-   
         <footer class="row">
           <div class="large-12 columns"><hr />
             <div class="row">
-   
               <div class="large-6 columns">
-                <p>ยฉ Copyright no one at all. Go to town.</p>
+                <p>&copy; Copyright no one at all. Go to town.</p>
               </div>
-   
               <div class="large-6 columns">
                 <ul class="inline-list right">
                   <li><a href="#">Link 1</a></li>
@@ -103,13 +94,10 @@
                   <li><a href="#">Link 4</a></li>
                 </ul>
               </div>
-   
             </div>
           </div>
         </footer>
-   
       <!-- End Footer -->
-   
       </div>
     </div>
     <%= javascript_include_tag "application" %>
app/views/layouts/public.html.erb
@@ -13,7 +13,7 @@
     <header>
       <div class="row">
         <div class="small-12 columns text-center">
-          <h1>Supply <span class="svg-container"><%= image_tag "sprite.svg#feather", alt: "Crow feather", class: "feather" %></span>Crow</h1>
+          <h1>Strong <span class="svg-container"><%= image_tag "sprite.svg#feather", alt: "Strong Lifters", class: "feather" %></span>Lifters</h1>
         </div>
       </div>
     </header>
app/views/user_mailer/registration_email.html.erb
@@ -1,2 +1,2 @@
 <p><%= "Hi, #{@username}." %></p>
-<p>The Supply Crow Team</p>
+<p>The Strong Lifters Team</p>
app/views/user_mailer/registration_email.text.erb
@@ -1,3 +1,3 @@
 <%= "Hi, #{@username}." %>
 
-The Supply Crow Team
+The Strong Lifters Team
config/locales/en.yml
@@ -20,23 +20,6 @@
 # available at http://guides.rubyonrails.org/i18n.html.
 
 en:
-  items:
-    index:
-      item_name: 'Item name'
-      new_item_button: 'Create item'
-    form:
-      name: 'Name'
-      description: 'Description'
-      serial_number: 'Serial Number'
-      purchase_price: 'Purchase Price'
-      purchase_date: 'Purchase date'
-      purchased_at: 'Purchase date'
-      create_button: 'Create item'
-    show:
-      delete_button: 'Delete'
-      delete_confirm: 'Confirm'
-      cancel_button: 'Cancel'
-      edit_button: 'Edit'
   registrations:
     new:
       username: "Username"
@@ -47,7 +30,7 @@ en:
       register_button: "Register"
       login_link: "Already have an account?"
     create:
-      success: "Thank you for registering. Welcome to Supply Crow."
+      success: "Thank you for registering."
   sessions:
     create:
       invalid_login: "Sorry, we cannot find that account."
config/routes.rb
@@ -2,7 +2,6 @@ Rails.application.routes.draw do
   root "sessions#new"
   resources :sessions, only: [:new, :create, :destroy]
   resources :registrations, only: [:new, :create]
-  resources :items
-  get "/dashboard" => "items#index", as: :dashboard
+  get "/dashboard" => "sessions#new", as: :dashboard
   get "/terms" => "static_pages#terms"
 end
db/migrate/20150228162534_create_items.rb
@@ -1,15 +0,0 @@
-class CreateItems < ActiveRecord::Migration
-  def change
-    create_table :items, id: :uuid do |t|
-      t.uuid :user_id, null: false
-      t.string :name
-      t.text :description
-      t.string :serial_number
-      t.decimal :purchase_price
-      t.datetime :purchased_at
-
-      t.timestamps null: false
-    end
-    add_index :items, :user_id
-  end
-end
db/schema.rb
@@ -11,25 +11,12 @@
 #
 # It's strongly recommended that you check this file into your version control system.
 
-ActiveRecord::Schema.define(version: 20150228162534) do
+ActiveRecord::Schema.define(version: 20150124163233) do
 
   # These are extensions that must be enabled in order to support this database
   enable_extension "plpgsql"
   enable_extension "uuid-ossp"
 
-  create_table "items", id: :uuid, default: "uuid_generate_v4()", force: :cascade do |t|
-    t.uuid     "user_id",        null: false
-    t.string   "name"
-    t.text     "description"
-    t.string   "serial_number"
-    t.decimal  "purchase_price"
-    t.datetime "purchased_at"
-    t.datetime "created_at",     null: false
-    t.datetime "updated_at",     null: false
-  end
-
-  add_index "items", ["user_id"], name: "index_items_on_user_id", using: :btree
-
   create_table "users", id: :uuid, default: "uuid_generate_v4()", force: :cascade do |t|
     t.string "username",        null: false
     t.string "email",           null: false
spec/controllers/application_controller_spec.rb
@@ -18,7 +18,7 @@ describe ApplicationController, type: :controller do
     let(:user) { create(:user) }
 
     it "allows the action to do it's thing" do
-      auth_user(user)
+      http_login(user)
       get :index
       expect(response.body).to eql("WHAT?")
     end
spec/controllers/items_controller_spec.rb
@@ -1,159 +0,0 @@
-require "rails_helper"
-
-RSpec.describe ItemsController, type: :controller do
-  context "when logged in" do
-    let(:user) { create(:user) }
-
-    before :each do
-      auth_user(user)
-    end
-
-    describe "#index" do
-      let(:other_user) { create(:user) }
-      let!(:my_item) { create(:item, user: user) }
-      let!(:their_item) { create(:item, user: other_user) }
-
-      it "loads all your items" do
-        get :index
-        expect(assigns(:items)).to match_array([my_item])
-      end
-    end
-
-    describe "#show" do
-      let(:item) { create(:item, user: user) }
-      let(:other_user) { create(:user) }
-      let(:other_guys_item) { create(:item, user: other_user) }
-
-      it "loads your item" do
-        get :show, id: item.id
-        expect(assigns(:item)).to eql(item)
-      end
-
-      it "does not load other peoples items" do
-        get :show, id: other_guys_item.id
-        expect(response.status).to eql(404)
-      end
-    end
-
-    describe "#new" do
-      it "loads up an empty item" do
-        get :new
-        expect(assigns(:item)).to_not be_nil
-      end
-
-      it "loads up the params for a new item" do
-        get :new, item: { name: "hammer" }
-        expect(assigns(:item).name).to eql("hammer")
-      end
-    end
-
-    describe "#edit" do
-      let(:my_item) { create(:item, user: user) }
-
-      it "loads the item to edit" do
-        get :edit, id: my_item.id
-        expect(assigns(:item)).to eql(my_item)
-      end
-
-      context "when attempting to edit someone elses item" do
-        let(:other_item) { create(:item, user: other_user) }
-        let(:other_user) { create(:user) }
-
-        it "returns a 404" do
-          get :edit, id: other_item.id
-
-          expect(assigns(:item)).to be_nil
-          expect(response.status).to eql(404)
-        end
-      end
-    end
-
-    describe "#create" do
-      let(:exclusions) { ["id", "user_id"] }
-      let(:item_params) do
-        build(:item).attributes.reject { |key, _| exclusions.include?(key) }
-      end
-
-      it "creates the new item" do
-        post :create, item: item_params
-
-        expect(Item.count).to eql(1)
-        item = Item.first
-        expect(item.user).to eql(user)
-        expect(item.name).to eql(item_params["name"])
-        expect(item.description).to eql(item_params["description"])
-        expect(item.serial_number).to eql(item_params["serial_number"])
-        expect(item.purchase_price).to eql(item_params["purchase_price"])
-        expect(item.purchased_at.to_i).to eql(item_params["purchased_at"].to_i)
-      end
-
-      it "redirects back to the dashboard" do
-        put :create, item: item_params
-
-        expect(response).to redirect_to(dashboard_path)
-      end
-
-      context "when some of the fields are invalid" do
-        it "displays the errors" do
-          post :create, item: { name: "" }
-          expect(flash[:warning]).to_not be_empty
-        end
-      end
-    end
-
-    describe "#update" do
-      let(:my_item) { create(:item, user: user) }
-      let(:item_params) { build(:item).attributes }
-
-      it "updates the item" do
-        patch :update, id: my_item.id, item: item_params
-
-        my_item.reload
-        expect(my_item.user).to eql(user)
-        expect(my_item.name).to eql(item_params["name"])
-        expect(my_item.description).to eql(item_params["description"])
-        expect(my_item.serial_number).to eql(item_params["serial_number"])
-        expect(my_item.purchase_price).to eql(item_params["purchase_price"])
-      end
-
-      it "redirects to the dashboard" do
-        patch :update, id: my_item.id, item: item_params
-
-        expect(response).to redirect_to(dashboard_path)
-      end
-    end
-
-    describe "#destroy" do
-      let(:my_item) { create(:item, user: user) }
-      let(:other_item) { create(:item, user: other_user) }
-      let(:other_user) { create(:user) }
-
-      it "deletes the item" do
-        delete :destroy, id: my_item.id
-
-        expect(Item.count).to eql(0)
-      end
-
-      it "cannot delete another persons item" do
-        delete :destroy, id: other_item.id
-
-        expect(response.status).to eql(404)
-      end
-
-      it "redirects to the dashboard" do
-        delete :destroy, id: my_item.id
-
-        expect(response).to redirect_to(dashboard_path)
-      end
-    end
-  end
-
-  context "when not logged in" do
-    describe "#index" do
-      it "redirects to the login page" do
-        get :index
-        expect(response).to redirect_to(new_session_path)
-      end
-    end
-  end
-end
spec/factories/items.rb
@@ -1,9 +0,0 @@
-FactoryGirl.define do
-  factory :item do
-    name FFaker::Name.name
-    description FFaker::HipsterIpsum.words(50)
-    serial_number SecureRandom.uuid
-    purchase_price { (rand(1_000) + rand).round(2) }
-    purchased_at DateTime.now
-  end
-end
spec/features/items_spec.rb
@@ -1,53 +0,0 @@
-require "rails_helper"
-
-feature "items", type: :feature, js: true do
-  describe "GET /items" do
-    subject { ItemsPage.new }
-    let(:user) { create(:user) }
-    let!(:item) { create(:item, user: user) }
-
-    context "when logged in" do
-      before :each do
-        subject.login_with(user.username, "password")
-        subject.visit_page
-      end
-
-      it "loads a list of items" do
-        expect(page).to have_content(item.name)
-      end
-
-      it "can start to add a new item" do
-        subject.add_item("new item")
-        expect(page).to have_selector("input[value='new item']")
-      end
-    end
-
-    context "not logged in" do
-      it 'redirects you to the login page' do
-        subject.visit_page
-        expect(page.current_path).to eql(new_session_path)
-      end
-    end
-  end
-
-  describe "POST /items" do
-    subject { NewItemPage.new }
-    let(:user) { create(:user) }
-
-    before :each do
-      subject.login_with(user.username, "password")
-      subject.visit_page
-    end
-
-    it "creates a new item" do
-      subject.create_item(
-        name: "hammer",
-        description: "for hammering things",
-        serial_number: "123456",
-        purchase_price: "1.99",
-        purchased_at: "2015-01-01",
-      )
-      expect(subject).to have_content("hammer")
-    end
-  end
-end
spec/javascripts/calculator_spec.js.coffee
@@ -1,4 +1,4 @@
 #= require models/calculator
 describe "Calculator", ->
   it "adds two digits", ->
-    expect(new SupplyCrow.Calculator().add(2, 2)).toBe(4)
+    expect(new StrongLifters.Calculator().add(2, 2)).toBe(4)
spec/mailers/user_mailer_spec.rb
@@ -5,7 +5,7 @@ RSpec.describe UserMailer, type: :mailer do
     let(:user) { double User, username: "blah", email:"blah@example.com" }
     let(:mail) { UserMailer.registration_email(user) }
     it "renders the subject" do
-      expect(mail.subject).to eql("Welcome to Supply Crow.")
+      expect(mail.subject).to eql("Welcome to Strong Lifters.")
     end
     it "renders the recipient email" do
       expect(mail.to).to eql([user.email])
spec/models/item_spec.rb
@@ -1,19 +0,0 @@
-require "rails_helper"
-
-RSpec.describe Item, type: :model do
-  describe "validations" do
-    let(:user) { create(:user) }
-
-    it "validates the presence of a user" do
-      item = build(:item, user: nil)
-      expect(item).to_not be_valid
-      expect(item.errors[:user]).to_not be_empty
-    end
-
-    it "validates the presence of a name" do
-      item = build(:item, user: user, name: nil)
-      expect(item).to_not be_valid
-      expect(item.errors[:name]).to_not be_empty
-    end
-  end
-end
spec/routing/dashboard_routing_spec.rb
@@ -2,6 +2,6 @@ require "rails_helper"
 
 RSpec.describe "/dashboard", type: :routing do
   it "routes to the items listing" do
-    expect(get: "/dashboard").to route_to("items#index")
+    expect(get: "/dashboard").to route_to("sessions#new")
   end
 end
spec/routing/items_routing_spec.rb
@@ -1,33 +0,0 @@
-require "rails_helper"
-
-RSpec.describe ItemsController, type: :routing do
-  describe "routing" do
-    it "routes to #index" do
-      expect(get: "/items").to route_to("items#index")
-    end
-
-    it "routes to #new" do
-      expect(get: "/items/new").to route_to("items#new")
-    end
-
-    it "routes to #show" do
-      expect(get: "/items/1").to route_to("items#show", id: "1")
-    end
-
-    it "routes to #edit" do
-      expect(get: "/items/1/edit").to route_to("items#edit", id: "1")
-    end
-
-    it "routes to #create" do
-      expect(post: "/items").to route_to("items#create")
-    end
-
-    it "routes to #update" do
-      expect(put: "/items/1").to route_to("items#update", id: "1")
-    end
-
-    it "routes to #destroy" do
-      expect(delete: "/items/1").to route_to("items#destroy", id: "1")
-    end
-  end
-end
spec/support/pages/items_page.rb
@@ -1,36 +0,0 @@
-require_relative "../page_model.rb"
-
-class ItemsPage < PageModel
-  def initialize
-    super dashboard_path
-  end
-
-  def add_item(item_name)
-    within "#new_item" do
-      fill_in I18n.translate("items.index.item_name"), with: item_name
-      click_button I18n.translate("items.index.new_item_button")
-    end
-  end
-end
-
-class NewItemPage < PageModel
-  def initialize
-    super new_item_path
-  end
-
-  def create_item(name:, 
-                  description: '',
-                  serial_number: '',
-                  purchase_price: '',
-                  purchased_at: ''
-                 )
-    within "#new_item" do
-      fill_in I18n.translate("items.form.name"), with: name
-      fill_in I18n.translate("items.form.description"), with: description
-      fill_in I18n.translate("items.form.serial_number"), with: serial_number
-      fill_in I18n.translate("items.form.purchase_price"), with: purchase_price
-      fill_in I18n.translate("items.form.purchased_at"), with: purchased_at
-      click_button I18n.translate("items.form.create_button")
-    end
-  end
-end
spec/support/http_authentication.rb
@@ -1,5 +1,5 @@
 module HttpAuthentication
-  def auth_user(user)
+  def http_login(user)
     session[:user_id] = user.id
   end
 end
spec/spec_helper.rb
@@ -64,11 +64,6 @@ RSpec.configure do |config|
     config.default_formatter = 'doc'
   end
 
-  # Print the 10 slowest examples and example groups at the
-  # end of the spec run, to help surface which specs are running
-  # particularly slow.
-  config.profile_examples = 10
-
   # Run specs in random order to surface order dependencies. If you find an
   # order dependency and want to debug it, you can fix the order by providing
   # the seed, which is printed after each run.