Your app is complex. Testing it should be simple.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list | |
| apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9 | |
| apt-get -y --force-yes update | |
| apt-get -y --force-yes install lxc-docker | |
| echo "DOCKER_OPTS=\"-s=devicemapper\"" > /etc/default/docker | |
| service docker restart |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "active_support/all" | |
| require "forwardable" | |
| class Transition | |
| extend Forwardable | |
| def_delegators :params, :to_query, :to_json | |
| def initialize(han_transition) | |
| @han_transition = han_transition.symbolize_keys | |
| @params = han_transition[:params].symbolize_keys |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Models | |
| # app/models/user.rb | |
| class User < ActiveRecord::Base | |
| has_many :articles | |
| has_many :videos | |
| has_many :photos | |
| end | |
| # app/models/article.rb |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require "model_probe" | |
| User.extend ModelProbe | |
| User.fixture |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'test_helper' | |
| module ExampleEngine | |
| class SomeControllerTest < ActionController::TestCase | |
| setup do | |
| @routes = ExampleEngine::Engine.routes | |
| end | |
| test "index response" do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function (app) { | |
| var components = (app.components || (app.components = {})); | |
| app.components.ExampleComponent = React.createClass( | |
| mixins: [], | |
| propTypes: {...}, | |
| getInitialState: function () { | |
| return { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| app/assets/javascripts/modules | |
| lib/assets/javascripts/modules | |
| vendor/assets/javascripts/modules |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // vendor/assets/javascripts/modules/lodash.js | |
| //= require lodash |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # config/initializers/assets.rb | |
| Rails.application.config.tap do |config| | |
| config.assets.version = "1.0" | |
| paths = Dir[ | |
| Rails.root.join("app/assets/javascripts/modules/**/*"), | |
| Rails.root.join("lib/assets/javascripts/modules/**/*"), | |
| Rails.root.join("vendor/assets/javascripts/modules/**/*") | |
| ] |
OlderNewer