July 28, 2008
ROR E-Commerce application
Posted by revurikarunakar under Uncategorized | Tags: E-commerce, ROR E-Commerce application, Ruby on Rails E-Commerce application |Leave a Comment
July 28, 2008
Multiple Databases in Rails Application
Posted by revurikarunakar under Uncategorized | Tags: Mutilple databases, Rails multiple databases, self.table_name, Table name in Model |Leave a Comment
Simple way to connect to multiple database is
Just specify the database and table name in the models ( see the below example)
class Study < ActiveRecord::Base
#this must be defined before you call better_nested_set
def self.table_name
# “sso_development.users”
“sso_” + ENV[“RAILS_ENV”] + “.” + “studies”
end
end
I know that there are many ways to connect multiple databases
June 19, 2008
The HTML DOM is:
- A standard object model for HTML
- A standard programming interface for HTML
- Platform- and language-independent
- A W3C standard
The W3C is:
An Explanation of the Standards of the Web and the Group Who Determines Them
The D HTML is:
- It is a combination of HTML, JavaScript, DOM, and CSS
- DHTML stands for Dynamic HTML.
- DHTML is NOT a language or a web standard.
- DHTML is a TERM used to describe the technologies used to make web pages dynamic and interactive.
June 18, 2008
Ruby on Rails Tips
Posted by revurikarunakar under Web Development | Tags: Rails performance tips, Rails tips |Leave a Comment
I have seen the below link which has very beautiful ruby on rails tips.
http://www.fortytwo.gr/blog/18/9-Essential-Rails-Tips
June 18, 2008
Bypass methods in Story Runner
Posted by revurikarunakar under Integration testing | Tags: Bypass, Integration testing, Ruby on Rails, Story Runner |Leave a Comment
Story runner or integration testing doesn’t support the Stubs (or Mocks).
So, How can we handle the bypass methods in story runner?
Just follow the below steps to bypass the methods.
1. Check which method you want to bypass?
2. Add the corresponding method the corresponding helper file or the corresponding file
Example: I want to bypass the session_required required method of the module XXX.
So , I have copied the below code in the story_helper.rb method
It will return true.
#Bypass the before filters
module XXX
def session_required
@current_user = User.find(1)
return true
end
Thats it, You have restricted the methods in Story runner
June 18, 2008
Story Runner (Rails Integration Testing)
Posted by revurikarunakar under Web Development | Tags: Integration testing, Rspec Story Runner, Ruby on Rails, Story Runner |Leave a Comment
Story Runner is a Good behavioral integration “test” tool that been incorporated into Rspec and can be used in Ruby on Rail projects.
Below link gives u a small idea about it
http://www.vaporbase.com/postings/Beginners_Guide_to_Rspec_on_Story_Runner