-
Notifications
You must be signed in to change notification settings - Fork 210
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add annotation tests and remove redundant code * Add export tests * Remove some code * Fix codeclimate issues * Fix codeclimate issues * Fix rubocop block length * Removing rubocop cfg since #547 and renaming tests
- Loading branch information
1 parent
62eec1e
commit 03deef1
Showing
10 changed files
with
56 additions
and
46 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,21 @@ | ||
require 'test_helper' | ||
|
||
class ExportTest < ActiveSupport::TestCase | ||
test "count methods" do | ||
test 'should count methods' do | ||
average = Export.all.map(&:cm_per_pixel).sum/Export.count | ||
assert_not_nil Export.average_cm_per_pixel | ||
assert_equal average, Export.average_cm_per_pixel | ||
assert_not_nil Export.histogram_cm_per_pixel | ||
assert_not_nil Export.histogram_cm_per_pixel_in_tens | ||
assert_not_nil Export.export_count | ||
assert_not_nil Export.exporting | ||
|
||
Export.delete_all | ||
assert_empty Export.histogram_cm_per_pixel | ||
assert_equal 0, Export.average_cm_per_pixel | ||
end | ||
|
||
test "export running" do | ||
test 'should export running' do | ||
assert !Export.last.running? | ||
end | ||
end |
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,4 @@ | ||
require 'test_helper' | ||
|
||
class NodeTest < ActiveSupport::TestCase | ||
# Replace this with your real tests. | ||
test "the truth" do | ||
assert true | ||
end | ||
end |
This file contains 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
This file contains 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
This file contains 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