<commit_before>/**
 * Copyright reelyActive 2015
 * We believe in an open Internet of Things
 */
 
var expect  = require("chai").expect;
var advlib = require("../../index.js");
var assert = require ('assert'); 

var payload = '421655daba50e1fe0201050c097265656c794163746976650100' ;
var expectedresult =  {

              type: 'ADVA-48',
                value: 'fee150bada55',
                advHeader: 
                 { type: 'ADV_NONCONNECT_IND',
                   length: 22,
                   txAdd: 'random',
                   rxAdd: 'public' },
                advData: 
                 { flags: [ 'LE Limited Discoverable Mode', 'BR/EDR Not Supported' ],
                   completeLocalName: 'reelyActive' } 

               }

describe("Wireless Packet Decoder", function() {
  describe("Payload to Packet Info Decoder", function() {
    it("converts the a hexadecimal payload to a JSON packet", function() {
        assert.deepEqual(advlib.process(payload), expectedresult);
      <commit_msg>testing with mocha js<commit_after>/**
 * Copyright reelyActive 2015
 * We believe in an open Internet of Things
 */

var advlib = require("../../index.js");
var assert = require ('assert'); 

var payload = '421655daba50e1fe0201050c097265656c794163746976650100' ;
var expectedresult =  {

              type: 'ADVA-48',
                value: 'fee150bada55',
                advHeader: 
                 { type: 'ADV_NONCONNECT_IND',
                   length: 22,
                   txAdd: 'random',
                   rxAdd: 'public' },
                advData: 
                 { flags: [ 'LE Limited Discoverable Mode', 'BR/EDR Not Supported' ],
                   completeLocalName: 'reelyActive' } 

               }

describe("Wireless Packet Decoder", function() {
  describe("Payload to Packet Info Decoder", function() {
    it("converts the a hexadecimal payload to a JSON packet", function() {
        assert.deepEqual(advlib.process(payload), expectedresult);
      
{'fraction_non_alphanumeric': 0.11099949773982923, 'fraction_numerical': 0.0562531391260673, 'mean_word_length': 2.0412213740458016, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6177983', 'n_tokens_mistral': 646, 'n_tokens_neox': 540, 'n_words': 146}