Files: f1015df18e879cbad5fe6cb3f49e783d6063f2c3 / test / index.js
420 bytesRaw
1 | var test = require('tape') |
2 | var fs = require('fs') |
3 | var path = require('path') |
4 | |
5 | var wpa = require('../') |
6 | |
7 | var networksTxt = fs.readFileSync(path.join(__dirname, 'networks.txt'), 'ascii') |
8 | var networksObj = require('./networks.json') |
9 | |
10 | test('decode', function (t) { |
11 | t.deepEquals(wpa.decode(networksTxt), networksObj) |
12 | t.end() |
13 | }) |
14 | |
15 | test('encode', function (t) { |
16 | t.deepEquals(wpa.encode(networksObj), networksTxt) |
17 | t.end() |
18 | }) |
19 |
Built with git-ssb-web