mohayonao/SCScript

View on GitHub
src/sc/lang/iterator_test.js

Summary

Maintainability
F
1 mo
Test Coverage

File iterator_test.js has 591 lines of code (exceeds 250 allowed). Consider refactoring.
Open

describe("sc.lang.iterator", function() {
  "use strict";

  var $$ = sc.test.object;
  var $  = sc.lang.$;
Severity: Major
Found in src/sc/lang/iterator_test.js - About 1 day to fix

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("float$reverseDo", function() {
          var iter = sc.lang.iterator.float$reverseDo($$(5.0));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 2 days to fix
    src/sc/lang/iterator_test.js on lines 405..418

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 379.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("float$do", function() {
          var iter = sc.lang.iterator.float$do($$(5.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 2 days to fix
    src/sc/lang/iterator_test.js on lines 445..458

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 379.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$for downto", function() {
          var iter = sc.lang.iterator.number$for($$(5), $$(1));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 136..149
    src/sc/lang/iterator_test.js on lines 295..308
    src/sc/lang/iterator_test.js on lines 310..323
    src/sc/lang/iterator_test.js on lines 469..482
    src/sc/lang/iterator_test.js on lines 484..497

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$for", function() {
          var iter = sc.lang.iterator.float$for($$(1.5), $$(5.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 136..149
    src/sc/lang/iterator_test.js on lines 151..164
    src/sc/lang/iterator_test.js on lines 295..308
    src/sc/lang/iterator_test.js on lines 310..323
    src/sc/lang/iterator_test.js on lines 484..497

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$for upto", function() {
          var iter = sc.lang.iterator.integer$for($$(1), $$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 136..149
    src/sc/lang/iterator_test.js on lines 151..164
    src/sc/lang/iterator_test.js on lines 310..323
    src/sc/lang/iterator_test.js on lines 469..482
    src/sc/lang/iterator_test.js on lines 484..497

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$for", function() {
          var iter = sc.lang.iterator.float$for($$(5.5), $$(1.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 136..149
    src/sc/lang/iterator_test.js on lines 151..164
    src/sc/lang/iterator_test.js on lines 295..308
    src/sc/lang/iterator_test.js on lines 310..323
    src/sc/lang/iterator_test.js on lines 469..482

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$for downto", function() {
          var iter = sc.lang.iterator.integer$for($$(5), $$(1));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 136..149
    src/sc/lang/iterator_test.js on lines 151..164
    src/sc/lang/iterator_test.js on lines 295..308
    src/sc/lang/iterator_test.js on lines 469..482
    src/sc/lang/iterator_test.js on lines 484..497

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$for upto", function() {
          var iter = sc.lang.iterator.number$for($$(1), $$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 151..164
    src/sc/lang/iterator_test.js on lines 295..308
    src/sc/lang/iterator_test.js on lines 310..323
    src/sc/lang/iterator_test.js on lines 469..482
    src/sc/lang/iterator_test.js on lines 484..497

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 344.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

        it("integer$reverseDo", function() {
          var iter = sc.lang.iterator.integer$reverseDo($$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 3 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 88..101
    src/sc/lang/iterator_test.js on lines 112..125
    src/sc/lang/iterator_test.js on lines 247..260

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 339.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

        it("integer$reverseDo", function() {
          var iter = sc.lang.iterator.number$reverseDo($$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 3 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 88..101
    src/sc/lang/iterator_test.js on lines 247..260
    src/sc/lang/iterator_test.js on lines 271..284

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 339.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

        it("integer$do", function() {
          var iter = sc.lang.iterator.integer$do($$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 3 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 88..101
    src/sc/lang/iterator_test.js on lines 112..125
    src/sc/lang/iterator_test.js on lines 271..284

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 339.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 4 locations. Consider refactoring.
    Open

        it("number$do", function() {
          var iter = sc.lang.iterator.number$do($$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 3 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 112..125
    src/sc/lang/iterator_test.js on lines 247..260
    src/sc/lang/iterator_test.js on lines 271..284

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 339.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("array$do", function() {
          var iter = sc.lang.iterator.array$do($$([ 1, 2, 3, 4 ]));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 601..613

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 302.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("array$reverseDo", function() {
          var iter = sc.lang.iterator.array$reverseDo($$([ 1, 2, 3, 4 ]));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 578..590

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 302.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("number$forBy downto", function() {
          var iter = sc.lang.iterator.number$forBy($$(5), $$(1), $$(-2));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 338..349

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 267.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("integer$forBy downto", function() {
          var iter = sc.lang.iterator.integer$forBy($$(5), $$(1), $$(-2));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 179..190

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 267.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("number$forBy upto", function() {
          var iter = sc.lang.iterator.number$forBy($$(1), $$(5), $$(2));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("number$forSeries upto", function() {
          var iter = sc.lang.iterator.number$forSeries($$(1), $$(3), $$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("float$forSeries upto", function() {
          var iter = sc.lang.iterator.float$forSeries($$(1.5), $$(3.5), $$(5.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("number$forSeries downto", function() {
          var iter = sc.lang.iterator.number$forSeries($$(5), $$(3), $$(1));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("integer$forSeries", function() {
          var iter = sc.lang.iterator.integer$forSeries($$(5), $$(3), $$(1));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("float$forSeries downto", function() {
          var iter = sc.lang.iterator.float$forSeries($$(5.5), $$(3.5), $$(1.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("integer$forSeries", function() {
          var iter = sc.lang.iterator.integer$forSeries($$(1), $$(3), $$(5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 325..336
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 8 locations. Consider refactoring.
    Open

        it("integer$forBy upto", function() {
          var iter = sc.lang.iterator.integer$forBy($$(1), $$(5), $$(2));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 7 other locations - About 1 day to fix
    src/sc/lang/iterator_test.js on lines 166..177
    src/sc/lang/iterator_test.js on lines 212..223
    src/sc/lang/iterator_test.js on lines 225..236
    src/sc/lang/iterator_test.js on lines 370..381
    src/sc/lang/iterator_test.js on lines 383..394
    src/sc/lang/iterator_test.js on lines 543..554
    src/sc/lang/iterator_test.js on lines 556..567

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 265.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
            expect(iter.next() , 2).to.deep.equal($$([ $.Float(1.5), 0 ])._);
            expect(iter.next() , 3).to.deep.equal($$([ $.Float(4.0), 1 ])._);
            expect(iter.hasNext, 4).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 7 hrs to fix
    src/sc/lang/iterator_test.js on lines 514..520

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 189.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.true;
            expect(iter.next() , 2).to.deep.equal($$([ $.Float(5.5), 0 ])._);
            expect(iter.next() , 3).to.deep.equal($$([ $.Float(3.0), 1 ])._);
            expect(iter.hasNext, 4).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 7 hrs to fix
    src/sc/lang/iterator_test.js on lines 502..508

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 189.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$forBy step=0", function() {
          var iter = sc.lang.iterator.integer$forBy($$(1), $$(5), $$(0));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 192..199
    src/sc/lang/iterator_test.js on lines 238..245
    src/sc/lang/iterator_test.js on lines 396..403
    src/sc/lang/iterator_test.js on lines 523..530
    src/sc/lang/iterator_test.js on lines 569..576

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$forSeries step=0", function() {
          var iter = sc.lang.iterator.float$forSeries($$(1.5), $$(0), $$(3.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 192..199
    src/sc/lang/iterator_test.js on lines 238..245
    src/sc/lang/iterator_test.js on lines 351..358
    src/sc/lang/iterator_test.js on lines 396..403
    src/sc/lang/iterator_test.js on lines 523..530

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$forBy step=0", function() {
          var iter = sc.lang.iterator.number$forBy($$(1), $$(5), $$(0));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 238..245
    src/sc/lang/iterator_test.js on lines 351..358
    src/sc/lang/iterator_test.js on lines 396..403
    src/sc/lang/iterator_test.js on lines 523..530
    src/sc/lang/iterator_test.js on lines 569..576

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$forSeries ignore", function() {
          var iter = sc.lang.iterator.number$forSeries($$(1), $$(0), $$(3));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 192..199
    src/sc/lang/iterator_test.js on lines 351..358
    src/sc/lang/iterator_test.js on lines 396..403
    src/sc/lang/iterator_test.js on lines 523..530
    src/sc/lang/iterator_test.js on lines 569..576

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$forBy step=0", function() {
          var iter = sc.lang.iterator.float$forBy($$(1.5), $$(5.5), $$(0));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 192..199
    src/sc/lang/iterator_test.js on lines 238..245
    src/sc/lang/iterator_test.js on lines 351..358
    src/sc/lang/iterator_test.js on lines 396..403
    src/sc/lang/iterator_test.js on lines 569..576

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$forSeries", function() {
          var iter = sc.lang.iterator.integer$forSeries($$(1), $$(0), $$(3));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 4 hrs to fix
    src/sc/lang/iterator_test.js on lines 192..199
    src/sc/lang/iterator_test.js on lines 238..245
    src/sc/lang/iterator_test.js on lines 351..358
    src/sc/lang/iterator_test.js on lines 523..530
    src/sc/lang/iterator_test.js on lines 569..576

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 115.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$reverseDo neg", function() {
          var iter = sc.lang.iterator.number$reverseDo($$(-5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 103..110
    src/sc/lang/iterator_test.js on lines 262..269
    src/sc/lang/iterator_test.js on lines 286..293
    src/sc/lang/iterator_test.js on lines 420..427
    src/sc/lang/iterator_test.js on lines 460..467

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$do neg", function() {
          var iter = sc.lang.iterator.float$do($$(-5.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 103..110
    src/sc/lang/iterator_test.js on lines 127..134
    src/sc/lang/iterator_test.js on lines 262..269
    src/sc/lang/iterator_test.js on lines 286..293
    src/sc/lang/iterator_test.js on lines 460..467

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("number$do neg", function() {
          var iter = sc.lang.iterator.number$do($$(-5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 127..134
    src/sc/lang/iterator_test.js on lines 262..269
    src/sc/lang/iterator_test.js on lines 286..293
    src/sc/lang/iterator_test.js on lines 420..427
    src/sc/lang/iterator_test.js on lines 460..467

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$do neg", function() {
          var iter = sc.lang.iterator.integer$do($$(-5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 103..110
    src/sc/lang/iterator_test.js on lines 127..134
    src/sc/lang/iterator_test.js on lines 286..293
    src/sc/lang/iterator_test.js on lines 420..427
    src/sc/lang/iterator_test.js on lines 460..467

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("integer$reverseDo neg", function() {
          var iter = sc.lang.iterator.integer$reverseDo($$(-5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 103..110
    src/sc/lang/iterator_test.js on lines 127..134
    src/sc/lang/iterator_test.js on lines 262..269
    src/sc/lang/iterator_test.js on lines 420..427
    src/sc/lang/iterator_test.js on lines 460..467

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        it("float$reverseDo neg", function() {
          var iter = sc.lang.iterator.float$reverseDo($$(-5.5));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 5 other locations - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 103..110
    src/sc/lang/iterator_test.js on lines 127..134
    src/sc/lang/iterator_test.js on lines 262..269
    src/sc/lang/iterator_test.js on lines 286..293
    src/sc/lang/iterator_test.js on lines 420..427

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 107.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("array$do empty", function() {
          var iter = sc.lang.iterator.array$do($$([]));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 615..622

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 106.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        it("array$reverseDo empty", function() {
          var iter = sc.lang.iterator.array$reverseDo($$([]));
    
          testTwice(iter, function(iter) {
            expect(iter.hasNext, 1).to.be.false;
    Severity: Major
    Found in src/sc/lang/iterator_test.js and 1 other location - About 3 hrs to fix
    src/sc/lang/iterator_test.js on lines 592..599

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 106.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

          var iter = sc.lang.iterator.function$while(
            $$(function() {
              return $$(i++ < 3);
            })
          );
    Severity: Minor
    Found in src/sc/lang/iterator_test.js and 1 other location - About 30 mins to fix
    src/sc/lang/iterator_test.js on lines 37..41

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 45.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

          var iter = sc.lang.iterator.function$while(
            $$(function() {
              return $$(x++ < 5);
            })
          );
    Severity: Minor
    Found in src/sc/lang/iterator_test.js and 1 other location - About 30 mins to fix
    src/sc/lang/iterator_test.js on lines 656..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 45.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    There are no issues that match your filters.

    Category
    Status