Showing 2,813 of 2,813 total issues
Block has too many lines. [331/25] Open
describe AssignmentsController do
let(:assignment) do
build(:assignment, id: 1, name: 'test assignment', instructor_id: 6, staggered_deadline: true, directory_path: 'same path',
participants: [build(:participant)], teams: [build(:assignment_team)], course_id: 1)
end
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Assignment Branch Condition size for complete is too high. [222.9/15] Open
def complete(count, answer = nil, questionnaire_min, questionnaire_max, dropdown_or_scale)
if self.size.nil?
cols = '70'
rows = '1'
else
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Block has too many lines. [326/25] Open
describe CollusionCycle do
#
# assignment participant -----
# ^ |
# | V
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
File tree_display.jsx
has 1153 lines of code (exceeds 250 allowed). Consider refactoring. Open
jQuery(document).ready(function() {
// This preloadedImages function is refered from http://jsfiddle.net/slashingweapon/8jAeu/
// Actually I am not using the values in preloadedImages, but image loading speed is indeed getting faster
var preloadedImages = []
function preloadImages() {
Block has too many lines. [302/25] Open
describe ResponseController do
let(:assignment) { build(:assignment, instructor_id: 6) }
let(:instructor) { build(:instructor, id: 6) }
let(:participant) { build(:participant, id: 1, user_id: 6, assignment: assignment) }
let(:review_response) { build(:response, id: 1, map_id: 1) }
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [289/25] Open
describe AssignmentForm do
let(:assignment) { build(:assignment, id: 1) }
let(:due_date) { build(:assignment_due_date) }
let(:assignment_form) { AssignmentForm.new }
let(:user) { double('Instructor', timezonepref: 'Eastern Time (US & Canada)') }
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Module has too many lines. [302/100] Open
module ReviewMappingHelper
def create_report_table_header(headers = {})
table_header = "<div class = 'reviewreport'>\
<table width='100% cellspacing='0' cellpadding='2' border='0' class='table table-striped'>\
<tr bgcolor='#CCCCCC'>"
- Read upRead up
- Exclude checks
This cop checks if the length a module exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Block has too many lines. [262/25] Open
describe TreeDisplayController do
# Airbrake-1517247902792549741
describe "#list" do
it "should not redirect to tree_display#list if current user is an instructor" do
user = build(:instructor)
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Assignment Branch Condition size for save_topic_deadlines is too high. [162.6/15] Open
def save_topic_deadlines
assignment = Assignment.find(params[:assignment_id])
@assignment_submission_due_dates = assignment.due_dates.select {|due_date| due_date.deadline_type_id == 1 }
@assignment_review_due_dates = assignment.due_dates.select {|due_date| due_date.deadline_type_id == 2 }
due_dates = params[:due_date]
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Block has too many lines. [227/25] Open
describe "creation page", js: true do
before(:each) do
(1..3).each do |i|
create(:course, name: "Course #{i}")
end
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [205/25] Open
describe Team do
let(:assignment) { build(:assignment, id: 1, name: 'no assgt') }
let(:participant) { build(:participant, user_id: 1) }
let(:participant2) { build(:participant, user_id: 2) }
let(:participant3) { build(:participant, user_id: 3) }
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Assignment Branch Condition size for scores is too high. [131.2/15] Open
def scores(questions)
scores = {}
scores[:participants] = {}
self.participants.each do |participant|
scores[:participants][participant.id.to_s.to_sym] = participant.scores(questions)
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Assignment Branch Condition size for import_from_hash is too high. [130.6/15] Open
def import_from_hash(session, params)
contents_hash = eval(params[:contents_hash])
if params[:model] == "AssignmentTeam" or params[:model] == "CourseTeam"
# contents_hash = eval(params[:contents_hash])
@header_integrated_body = hash_rows_with_headers(contents_hash[:header], contents_hash[:body])
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Block has too many lines. [196/25] Open
describe "Staggered deadline test" do
before(:each) do
# assignment and topic
create(:assignment,
name: "Assignment1665",
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Assignment Branch Condition size for send_post_request is too high. [125.8/15] Open
def send_post_request
# https://www.socialtext.net/open/very_simple_rest_in_ruby_part_3_post_to_create_a_new_workspace
req = Net::HTTP::Post.new('/reputation/calculations/reputation_algorithms', initheader = {'Content-Type' => 'application/json', 'charset' => 'utf-8'})
curr_assignment_id = (params[:assignment_id].empty? ? '724' : params[:assignment_id])
req.body = json_generator(curr_assignment_id, params[:another_assignment_id].to_i, params[:round_num].to_i, 'peer review grades').to_json
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Assignment Branch Condition size for update_quiz is too high. [124.7/15] Open
def update_quiz
@questionnaire = Questionnaire.find(params[:id])
if @questionnaire.nil?
redirect_to controller: 'submitted_content', action: 'view', id: params[:pid]
return
- Read upRead up
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Block has too many lines. [192/25] Open
xdescribe "Team Creation" do
before(:each) do
create(:assignment)
create_list(:participant, 3)
create(:assignment_node)
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [191/25] Open
describe "Assignment Topic Suggestion Test" do
before(:each) do
create(:assignment, name: 'Assignment_suggest_topic', allow_suggestions: true)
create_list(:participant, 3)
create(:assignment_node)
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [188/25] Open
describe ReviewResponseMap do
let(:team) { build(:assignment_team, id: 1, name: 'team no name', assignment: assignment, users: [student], parent_id: 1) }
let(:team1) { build(:assignment_team, id: 2, name: 'team has name', assignment: assignment, users: [student]) }
let(:review_response_map) { build(:review_response_map, id: 1, assignment: assignment, reviewer: participant, reviewee: team) }
let(:review_response_map1) do
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.
Block has too many lines. [182/25] Open
xdescribe "SimiCheckWebservice" do
def poll(comp_id)
is_success = false
until is_success
begin
- Read upRead up
- Exclude checks
This cop checks if the length of a block exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable. The cop can be configured to ignore blocks passed to certain methods.