Sha256: a562fd1a57bdcde35b24222723b2b5a71d4e2d241425c9f97cd565984e448a6c

Contents?: true

Size: 1014 Bytes

Versions: 141

Compression:

Stored size: 1014 Bytes

Contents

var atbash = require('./atbash-cipher');

describe('encode', function () {
  it('encodes no', function () {
    expect(atbash.encode('no')).toEqual('ml');
  });

  xit('encodes yes', function () {
    expect(atbash.encode('yes')).toEqual('bvh');
  });

  xit('encodes OMG', function () {
    expect(atbash.encode('OMG')).toEqual('lnt');
  });

  xit('encodes O M G', function () {
    expect(atbash.encode('O M G')).toEqual('lnt');
  });

  xit('encodes long words', function () {
    expect(atbash.encode('mindblowingly')).toEqual('nrmwy oldrm tob');
  });

  xit('encodes numbers', function () {
    expect(atbash.encode('Testing, 1 2 3, testing.'))
      .toEqual('gvhgr mt123 gvhgr mt');
  });

  xit('encodes sentences', function () {
    expect(atbash.encode('Truth is fiction.')).toEqual('gifgs rhurx grlm');
  });

  xit('encodes all the things', function () {
    expect(atbash.encode('The quick brown fox jumps over the lazy dog.'))
      .toEqual('gsvjf rxpyi ldmul cqfnk hlevi gsvoz abwlt');
  });
});

Version data entries

141 entries across 141 versions & 1 rubygems

Version Path
trackler-2.2.1.180 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.179 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.178 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.177 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.176 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.175 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.174 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.173 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.172 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.171 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.170 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.169 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.167 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.166 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.165 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.164 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.163 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.162 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.161 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js
trackler-2.2.1.160 tracks/javascript/exercises/atbash-cipher/atbash-cipher.spec.js