Commit e0b0cbde246d50edfdc0f4d7445c55dc758bb067
Committed by
David Silva
1 parent
57ae8cf1
Exists in
master
and in
5 other branches
Remove trailing whitespace
Signed-off-by: Gabriela Navarro <navarro1703@gmail.com> Signed-off-by: Parley Martins <parley@outlook.com>
Showing
15 changed files
with
29 additions
and
34 deletions
Show diff stats
db/migrate/20140528193905_create_software_infos_table.rb
| ... | ... | @@ -3,11 +3,11 @@ class CreateSoftwareInfosTable < ActiveRecord::Migration |
| 3 | 3 | create_table :software_infos do |t| |
| 4 | 4 | t.references :license_info |
| 5 | 5 | t.references :community |
| 6 | - t.boolean :e_mag, :default => false | |
| 7 | - t.boolean :icp_brasil,:default => false | |
| 8 | - t.boolean :intern, :default => false | |
| 9 | - t.boolean :e_ping, :default => false | |
| 10 | - t.boolean :e_arq, :default => false | |
| 6 | + t.boolean :e_mag, :default => false | |
| 7 | + t.boolean :icp_brasil,:default => false | |
| 8 | + t.boolean :intern, :default => false | |
| 9 | + t.boolean :e_ping, :default => false | |
| 10 | + t.boolean :e_arq, :default => false | |
| 11 | 11 | t.string :name, :default => ' ' |
| 12 | 12 | t.string :operating_platform |
| 13 | 13 | t.string :demonstration_url | ... | ... |
db/migrate/20140812143218_remove_field_role_from_user.rb
db/migrate/20140814125947_add_new_fields_to_public_institution.rb
db/migrate/20140814131606_create_juridical_natures_table.rb
| ... | ... | @@ -3,11 +3,10 @@ class CreateJuridicalNaturesTable < ActiveRecord::Migration |
| 3 | 3 | create_table :juridical_natures do |t| |
| 4 | 4 | t.string :name |
| 5 | 5 | end |
| 6 | - | |
| 7 | 6 | SoftwareHelper.create_list_with_file("plugins/mpog_software/public/static/juridical_nature.txt", JuridicalNature) |
| 8 | 7 | end |
| 9 | 8 | |
| 10 | 9 | def down |
| 11 | - drop_table :juridical_natures | |
| 10 | + drop_table :juridical_natures | |
| 12 | 11 | end |
| 13 | 12 | end | ... | ... |
db/migrate/20141007140419_add_finality_field_to_software_table.rb
lib/ext/user.rb
| ... | ... | @@ -18,9 +18,9 @@ class User |
| 18 | 18 | def email_has_already_been_used? |
| 19 | 19 | user_already_saved = User.find(:first, :conditions=>["email = ?", self.email]) |
| 20 | 20 | |
| 21 | - if user_already_saved.nil? | |
| 21 | + if user_already_saved.nil? | |
| 22 | 22 | primary_email_hasnt_been_used = User.primary_or_secondary_email_already_used?(self.email).empty? |
| 23 | - if !self.secondary_email.nil? and self.secondary_email.empty? | |
| 23 | + if !self.secondary_email.nil? and self.secondary_email.empty? | |
| 24 | 24 | self.secondary_email = nil |
| 25 | 25 | end |
| 26 | 26 | secondary_email_hasnt_been_used = User.primary_or_secondary_email_already_used?(self.secondary_email).empty? | ... | ... |
lib/institution.rb
| ... | ... | @@ -13,8 +13,8 @@ class Institution < ActiveRecord::Base |
| 13 | 13 | |
| 14 | 14 | has_and_belongs_to_many :users |
| 15 | 15 | |
| 16 | - attr_accessible :name, :acronym, :unit_code, :parent_code, :unit_type, | |
| 17 | - :sub_juridical_nature, :normalization_level, | |
| 16 | + attr_accessible :name, :acronym, :unit_code, :parent_code, :unit_type, | |
| 17 | + :sub_juridical_nature, :normalization_level, | |
| 18 | 18 | :version, :cnpj, :type, :governmental_power, :governmental_sphere, |
| 19 | 19 | :sisp, :juridical_nature, :corporate_name |
| 20 | 20 | |
| ... | ... | @@ -25,7 +25,7 @@ class Institution < ActiveRecord::Base |
| 25 | 25 | before_save :verify_institution_type |
| 26 | 26 | |
| 27 | 27 | belongs_to :community |
| 28 | - | |
| 28 | + | |
| 29 | 29 | scope :search_institution, lambda{ |value| |
| 30 | 30 | where("name ilike ? OR acronym ilike ?", "%#{value}%", "%#{value}%" ) |
| 31 | 31 | } | ... | ... |
lib/operating_system_helper.rb
| ... | ... | @@ -35,8 +35,8 @@ module OperatingSystemHelper |
| 35 | 35 | lambdas_list = [] |
| 36 | 36 | |
| 37 | 37 | if not show_information |
| 38 | - return operating_system_html_structure({:operating_system_name_id => "", :version => ""}, have_delete_button) if list_operating_system.nil? | |
| 39 | - | |
| 38 | + return operating_system_html_structure({:operating_system_name_id => "", :version => ""}, have_delete_button) if list_operating_system.nil? | |
| 39 | + | |
| 40 | 40 | list_operating_system.each do |operating_system| |
| 41 | 41 | lambdas_list << operating_system_html_structure(operating_system,have_delete_button) |
| 42 | 42 | end | ... | ... |
lib/public_institution.rb
| ... | ... | @@ -3,6 +3,4 @@ class PublicInstitution < Institution |
| 3 | 3 | validates :acronym, :allow_blank => true, :allow_nil => true, :uniqueness=>true |
| 4 | 4 | validates :cnpj, :uniqueness=>true |
| 5 | 5 | validates_format_of :cnpj, :with => /^\d{2}\.\d{3}\.\d{3}\/\d{4}\-\d{2}$/, :allow_nil => true, :allow_blank => true |
| 6 | - | |
| 7 | - | |
| 8 | 6 | end | ... | ... |
lib/search_catalog_block.rb
lib/software_language.rb
lib/software_language_helper.rb
| ... | ... | @@ -45,7 +45,7 @@ module SoftwareLanguageHelper |
| 45 | 45 | ActionView::Helpers::FormOptionsHelper, |
| 46 | 46 | ApplicationHelper |
| 47 | 47 | ) |
| 48 | - | |
| 48 | + | |
| 49 | 49 | lambdas_list = [] |
| 50 | 50 | |
| 51 | 51 | if not show_information |
| ... | ... | @@ -55,7 +55,7 @@ module SoftwareLanguageHelper |
| 55 | 55 | lambdas_list << language_html_structure(language) |
| 56 | 56 | end |
| 57 | 57 | |
| 58 | - else | |
| 58 | + else | |
| 59 | 59 | list_languages.each do |language| |
| 60 | 60 | lambdas_list << language_html_show_structure(language) |
| 61 | 61 | end | ... | ... |
test/unit/governmental_power_test.rb
| ... | ... | @@ -2,7 +2,7 @@ require File.dirname(__FILE__) + '/../../../../test/test_helper' |
| 2 | 2 | require File.dirname(__FILE__) + '/../helpers/institution_test_helper' |
| 3 | 3 | |
| 4 | 4 | class GovernmentalPowerTest < ActiveSupport::TestCase |
| 5 | - | |
| 5 | + | |
| 6 | 6 | def setup |
| 7 | 7 | @gov_sphere = GovernmentalSphere.create(:name=>"Some Gov Sphere") |
| 8 | 8 | @juridical_nature = JuridicalNature.create(:name => "Autarquia") | ... | ... |
test/unit/software_database_test.rb
| ... | ... | @@ -13,31 +13,31 @@ class SoftwareDatabaseTest < ActiveSupport::TestCase |
| 13 | 13 | end |
| 14 | 14 | |
| 15 | 15 | should "save if all informations of @software_database are filled" do |
| 16 | - assert @software_database.save, "Database should have been saved" | |
| 16 | + assert @software_database.save, "Database should have been saved" | |
| 17 | 17 | end |
| 18 | - | |
| 18 | + | |
| 19 | 19 | should "not save if database description id is empty" do |
| 20 | 20 | @software_database.database_description_id = nil |
| 21 | - assert !@software_database.save, "Database description must be filled" | |
| 21 | + assert !@software_database.save, "Database description must be filled" | |
| 22 | 22 | end |
| 23 | 23 | |
| 24 | 24 | should "not save if version is empty" do |
| 25 | 25 | @software_database.version = nil |
| 26 | - assert !@software_database.save, "Version must be filled" | |
| 26 | + assert !@software_database.save, "Version must be filled" | |
| 27 | 27 | end |
| 28 | 28 | |
| 29 | 29 | should "not save if version has more than 20 characters" do |
| 30 | 30 | @software_database.version = "a"*21 |
| 31 | - assert !@software_database.save, "Version must have until 20 characters" | |
| 31 | + assert !@software_database.save, "Version must have until 20 characters" | |
| 32 | 32 | end |
| 33 | 33 | |
| 34 | 34 | should "not save if operating system is empty" do |
| 35 | 35 | @software_database.operating_system = nil |
| 36 | - assert !@software_database.save, "Operating system must be filled" | |
| 36 | + assert !@software_database.save, "Operating system must be filled" | |
| 37 | 37 | end |
| 38 | - | |
| 38 | + | |
| 39 | 39 | should "not save if operating system has more than 20 characters" do |
| 40 | 40 | @software_database.operating_system = "a"*21 |
| 41 | - assert !@software_database.save, "Operating system must have until 20 characters" | |
| 41 | + assert !@software_database.save, "Operating system must have until 20 characters" | |
| 42 | 42 | end |
| 43 | 43 | end | ... | ... |
test/unit/software_language_validation.rb
| ... | ... | @@ -67,7 +67,7 @@ class SoftwareLanguageValidationTest < ActiveSupport::TestCase |
| 67 | 67 | software_info.intern = true |
| 68 | 68 | software_info.e_ping = true |
| 69 | 69 | software_info.e_arq = true |
| 70 | - software_info.operating_platform = 'GNU/Linux' | |
| 70 | + software_info.operating_platform = 'GNU/Linux' | |
| 71 | 71 | software_info.features = "Do a lot of things" |
| 72 | 72 | software_info.objectives = "All tests should pass !" |
| 73 | 73 | software_info | ... | ... |