ampersand-chess-state
Advanced tools
Comparing version 0.1.2 to 0.1.3
@@ -413,3 +413,3 @@ var raf = require('raf'); | ||
if (valid) { | ||
if (valid || pgn === '') { | ||
if (!fromEngine) { | ||
@@ -416,0 +416,0 @@ nextMoves = this._diffPgn(pgn); |
{ | ||
"name": "ampersand-chess-state", | ||
"description": "An evented chess library for movement, validation and result detection built on Ampersand.js.", | ||
"version": "0.1.2", | ||
"version": "0.1.3", | ||
"author": "Luke Karrys <luke@lukekarrys.com>", | ||
@@ -6,0 +6,0 @@ "bugs": "https://github.com/lukekarrys/ampersand-chess-state/issues", |
@@ -486,1 +486,15 @@ var test = require('tape'); | ||
}); | ||
test('Clear pgn with empty string', function (t) { | ||
var chess = new Chess({pgn: '1. f4 d6 2. e4 b5 3. g4 c6 4. a3 a6'}); | ||
t.equal(chess.pgnArray.length, 4); | ||
chess.pgn = ''; | ||
t.equal(chess.pgn, ''); | ||
t.equal(chess.fen, 'rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1'); | ||
t.equal(chess.start, true); | ||
t.end(); | ||
}); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
41407
836