@@ -55,6 +55,10 @@ describe('SimplexNoise', function() {
55
55
it ( 'should return a different value for a different input' , function ( ) {
56
56
assert . notEqual ( simplex . noise2D ( 0.1 , 0.2 ) , simplex . noise2D ( 0.101 , 0.202 ) ) ;
57
57
} ) ;
58
+ it ( 'should return a different output with a different seed' , function ( ) {
59
+ var simplex2 = new SimplexNoise ( new Alea ( 'other seed' ) ) ;
60
+ assert . notEqual ( simplex . noise2D ( 0.1 , 0.2 ) , simplex2 . noise2D ( 0.1 , 0.2 ) ) ;
61
+ } ) ;
58
62
it ( 'should return values between -1 and 1' , function ( ) {
59
63
for ( var x = 0 ; x < 10 ; x ++ ) {
60
64
for ( var y = 0 ; y < 10 ; y ++ ) {
@@ -76,6 +80,10 @@ describe('SimplexNoise', function() {
76
80
assert . notEqual ( simplex . noise3D ( 0.1 , 0.2 , 0.3 ) , simplex . noise3D ( 0.101 , 0.202 , 0.303 ) ) ;
77
81
assert . notEqual ( simplex . noise3D ( 0.1 , 0.2 , 0.3 ) , simplex . noise3D ( 0.1 , 0.2 , 0.303 ) ) ;
78
82
} ) ;
83
+ it ( 'should return a different output with a different seed' , function ( ) {
84
+ var simplex2 = new SimplexNoise ( new Alea ( 'other seed' ) ) ;
85
+ assert . notEqual ( simplex . noise2D ( 0.1 , 0.2 , 0.3 ) , simplex2 . noise2D ( 0.1 , 0.2 , 0.3 ) ) ;
86
+ } ) ;
79
87
it ( 'should return values between -1 and 1' , function ( ) {
80
88
for ( var x = 0 ; x < 10 ; x ++ ) {
81
89
for ( var y = 0 ; y < 10 ; y ++ ) {
@@ -97,6 +105,10 @@ describe('SimplexNoise', function() {
97
105
assert . notEqual ( simplex . noise4D ( 0.1 , 0.2 , 0.3 , 0.4 ) , simplex . noise4D ( 0.101 , 0.202 , 0.303 , 0.404 ) ) ;
98
106
assert . notEqual ( simplex . noise4D ( 0.1 , 0.2 , 0.3 , 0.4 ) , simplex . noise4D ( 0.1 , 0.2 , 0.3 , 0.404 ) ) ;
99
107
} ) ;
108
+ it ( 'should return a different output with a different seed' , function ( ) {
109
+ var simplex2 = new SimplexNoise ( new Alea ( 'other seed' ) ) ;
110
+ assert . notEqual ( simplex . noise2D ( 0.1 , 0.2 , 0.3 , 0.4 ) , simplex2 . noise2D ( 0.1 , 0.2 , 0.3 , 0.4 ) ) ;
111
+ } ) ;
100
112
it ( 'should return values between -1 and 1' , function ( ) {
101
113
for ( var x = 0 ; x < 10 ; x ++ ) {
102
114
for ( var y = 0 ; y < 10 ; y ++ ) {
0 commit comments