Testing of SMS App

Today I did testing of the SMS web app . Testing is done basically for checking the app is it’s working right or not.

There was basically I had to send message body on the appropriate contact number. I am using the message gateway providers link , that means I am sending all messages through their medium hence I need some keys for did that thing.

These keys are the private and secure keys (usually large encoded number for login info of our account ). These keys should be always kept secure and don’t tell anyone in any conditions because using these keys the hackers can easily get access to our account. So always remember to keep these keys secure.

Once you get key put it in the predefined format of the url with the contact number and the message body. With these all parameters that sms gateway provider will come to now that we want to send that message on this number which we mentioned in the url.

And the message will b send on that number in next few seconds.Its cool no?

While testing the app I learned about one new command which is Rails.logger.info or can be followed by any action which we want to tack or print on the log file. If we use the command we can see the hole process information and how the each and every method called one after one in sequence.

If suppose we have a method or variable called ‘create’ then if we write the command Rails.logger.info create then it will show the printed value of the create variable or method and all processing information about it.

There are six different levels of this logger these are: debug, info, warn, error, fatal and unknown corresponding to the log level numbers from 0 up to 5 respectively. To change the default log level, use

config.log_level = :warn # In any environment initializer, or

Rails.logger.level = 0 # at any time

This is useful when you want to log under development or staging, but you don’t want to flood your production log with unnecessary information.

The default Rails log level is debug in all environments.

Thanks for reading.