Default forbidDuplicateNames to true
This commit is contained in:
@@ -3345,9 +3345,9 @@ getJasmineRequireObj().Configuration = function(j$) {
|
|||||||
* error.
|
* error.
|
||||||
* @name Configuration#forbidDuplicateNames
|
* @name Configuration#forbidDuplicateNames
|
||||||
* @type boolean
|
* @type boolean
|
||||||
* @default false
|
* @default true
|
||||||
*/
|
*/
|
||||||
forbidDuplicateNames: false,
|
forbidDuplicateNames: true,
|
||||||
/**
|
/**
|
||||||
* Whether to issue warnings for certain deprecated functionality
|
* Whether to issue warnings for certain deprecated functionality
|
||||||
* every time it's used. If not set or set to false, deprecation warnings
|
* every time it's used. If not set or set to false, deprecation warnings
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ describe('Configuration', function() {
|
|||||||
expect(subject.specFilter()).toEqual(true);
|
expect(subject.specFilter()).toEqual(true);
|
||||||
expect(subject.hideDisabled).toEqual(false);
|
expect(subject.hideDisabled).toEqual(false);
|
||||||
expect(subject.autoCleanClosures).toEqual(true);
|
expect(subject.autoCleanClosures).toEqual(true);
|
||||||
expect(subject.forbidDuplicateNames).toEqual(false);
|
expect(subject.forbidDuplicateNames).toEqual(true);
|
||||||
expect(subject.verboseDeprecations).toEqual(false);
|
expect(subject.verboseDeprecations).toEqual(false);
|
||||||
expect(subject.detectLateRejectionHandling).toEqual(false);
|
expect(subject.detectLateRejectionHandling).toEqual(false);
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -487,14 +487,14 @@ describe('Env', function() {
|
|||||||
|
|
||||||
it('does not throw an error when called in a describe', function() {
|
it('does not throw an error when called in a describe', function() {
|
||||||
env.setParallelLoadingState('helpers');
|
env.setParallelLoadingState('helpers');
|
||||||
check();
|
check(1);
|
||||||
env.setParallelLoadingState('specs');
|
env.setParallelLoadingState('specs');
|
||||||
check();
|
check(2);
|
||||||
|
|
||||||
function check() {
|
function check(disambiguator) {
|
||||||
let done = false;
|
let done = false;
|
||||||
|
|
||||||
env.describe('a suite', function() {
|
env.describe('a suite ' + disambiguator, function() {
|
||||||
expect(function() {
|
expect(function() {
|
||||||
env.it('a spec');
|
env.it('a spec');
|
||||||
env.beforeAll(function() {});
|
env.beforeAll(function() {});
|
||||||
@@ -594,14 +594,14 @@ describe('Env', function() {
|
|||||||
|
|
||||||
it('does not throw an error when called in a describe', function() {
|
it('does not throw an error when called in a describe', function() {
|
||||||
env.setParallelLoadingState('helpers');
|
env.setParallelLoadingState('helpers');
|
||||||
check();
|
check(1);
|
||||||
env.setParallelLoadingState('specs');
|
env.setParallelLoadingState('specs');
|
||||||
check();
|
check(2);
|
||||||
|
|
||||||
function check() {
|
function check(disambiguator) {
|
||||||
let done = false;
|
let done = false;
|
||||||
|
|
||||||
env.describe('a suite', function() {
|
env.describe('a suite ' + disambiguator, function() {
|
||||||
expect(function() {
|
expect(function() {
|
||||||
env.it('a spec');
|
env.it('a spec');
|
||||||
env.afterAll(function() {});
|
env.afterAll(function() {});
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ describe('spec running', function() {
|
|||||||
env.it('should run nested suites', function() {
|
env.it('should run nested suites', function() {
|
||||||
foo++;
|
foo++;
|
||||||
});
|
});
|
||||||
env.it('should run nested suites', function() {
|
env.it('should run nested suites 2', function() {
|
||||||
bar++;
|
bar++;
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -95,9 +95,9 @@ getJasmineRequireObj().Configuration = function(j$) {
|
|||||||
* error.
|
* error.
|
||||||
* @name Configuration#forbidDuplicateNames
|
* @name Configuration#forbidDuplicateNames
|
||||||
* @type boolean
|
* @type boolean
|
||||||
* @default false
|
* @default true
|
||||||
*/
|
*/
|
||||||
forbidDuplicateNames: false,
|
forbidDuplicateNames: true,
|
||||||
/**
|
/**
|
||||||
* Whether to issue warnings for certain deprecated functionality
|
* Whether to issue warnings for certain deprecated functionality
|
||||||
* every time it's used. If not set or set to false, deprecation warnings
|
* every time it's used. If not set or set to false, deprecation warnings
|
||||||
|
|||||||
Reference in New Issue
Block a user