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
| class App < ActiveRecord::Base | |
| attr_accessible :image, :name, :ram | |
| has_many :versions | |
| has_many :installations | |
| belongs_to :user | |
| validates_presence_of :name | |
| mount_uploader :image, ApplogoUploader | |
| def actual_version | |
| versions.actual |
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
| // xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx Test Suite xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | |
| SpecsDatabaseCleaner() | |
| describe("Articles Behavior", function(){ | |
| it("should create an article", function(){ | |
| Factory.create("article"); | |
| var narticulos = cargarLista("ARTICULOS").listSize(); | |
| expect(1).toEqual(narticulos) | |
| }); |
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
| user = User.where(:email => "ron.evans@gmail.com") | |
| user.projects.each { |project| project.trackers.each { |tr| tr.enable!; tr.perform_options.update_attributes(:valid_auth => true, :failed_count => 0); tr.tracked_projects { |tr_p| tr_p.update_attributes(:retry_count => 0) }}} |
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
| ➜ fanvsfan git:(master) ✗ rake spec:integration | |
| /Users/cristianvasquez/.rvm/gems/ruby-1.9.3-p194@fanvsfan-193/gems/rspec-1.3.2/lib/spec/runner/options.rb:188: Use RbConfig instead of obsolete and deprecated Config. | |
| NOTE: Gem.source_index is deprecated, use Specification. It will be removed on or after 2011-11-01. | |
| Gem.source_index called from /Users/cristianvasquez/.rvm/gems/ruby-1.9.3-p194@fanvsfan-193/gems/rails-2.3.14/lib/rails/gem_dependency.rb:21. | |
| /Users/cristianvasquez/.rvm/gems/ruby-1.9.3-p194@fanvsfan-193/gems/activesupport-2.3.14/lib/active_support/inflector.rb:3:in `<top (required)>': iconv will be deprecated in the future, use String#encode instead. | |
| DEPRECATION WARNING: require "activesupport" is deprecated and will be removed in Rails 3. Use require "active_support" instead. (called from <top (required)> at /Users/cristianvasquez/.rvm/gems/ruby-1.9.3-p194@fanvsfan-193/gems/activesupport-2.3.14/lib/activesupport.rb:2) | |
| `include Capybara` is deprecated please use `include Capybara::DSL` instead. | |
| .... |
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
| # Path to your oh-my-zsh configuration. | |
| ZSH=$HOME/.oh-my-zsh | |
| # Set name of the theme to load. | |
| # Look in ~/.oh-my-zsh/themes/ | |
| # Optionally, if you set this to "random", it'll load a random theme each | |
| # time that oh-my-zsh is loaded. | |
| ZSH_THEME="robbyrussell" | |
| # Example aliases |
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
| ::Resque.queues.each do |queue| | |
| if queue.classify.constantize.ancestors.include? ::Resque::Plugins::Loner::UniqueJob | |
| ::Resque.peek(queue, 0, -1).each do |job_payload| | |
| hashes << ::Resque::Plugins::Loner::UniqueJob.redis_key(job_payload) | |
| end | |
| end unless queues_are_not_loners.include? queue | |
| end |
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
| current_dir = File.dirname __FILE__ | |
| require File.join(current_dir, '..', 'unit_spec_helper.rb') | |
| require 'ostruct' | |
| require 'clutch/model_performable' | |
| class PerformableTestClass | |
| include ::MongoMapper::Document | |
| include ::Clutch::Model::Performable | |
| def initialize |
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
| var exportaciones = { | |
| articulos: { | |
| referencia: "Referencia", | |
| name: "Nombre", | |
| grupos: "Grupos", | |
| "grupos.name": "Nombre Grupo", | |
| "tarifas_iva.porcentaje": "Porc IVA", | |
| precio_icluye_iva: "Precio incluye IVA", | |
| exist: "Existencias", | |
| f_ultima_comp: "Fecha Ultima Compra", |