<commit_before>MochaWeb?.testOnly ->

  assert = chai.assert

  describe 'Apollos', ->
    describe 'transactions', ->

      if Meteor.isServer

        before ->
          props =
            transactionId: 1
            scheduledTransactionId: 2
            personAliasId: 3
            fundId: 4
            fundName: '<NAME>'
            fundAmount: 5
            transactionCode: 6
            totalAmount: 7
            name: '<NAME>'
            source: 'Website'
            accountMask: 'Mr. Mask'
            currencyType: 'ACH'
            creditCardType: 'Visa'
            submittedDate: new Date("01-01-2000 UTC")
            processedDate: new Date("01-02-2000 UTC")

          Apollos.transactions.insert props

          it 'should exist', ->
            assert typeof Apollos.transcations is 'object'

          it 'should have transactionId', ->
            t = Apollos.transactions.findOne()
            assert typeof t.transactionId is 'number'
            assert.equal t.transactionId, 1

          it 'should have scheduledTransactionId', ->
            t = Apollos.transactions.findOne()
            assert typeof t.scheduledTransactionId is 'number'
            assert.equal t.scheduledTransactionId, 2

          it 'should have personAliasId', ->
            t = Apollos.transactions.findOne()
            assert typeof t.personAliasId is 'number'
            assert.equal t.personAliasId, 3

          it 'should have fundId', ->
            t = Apollos.transactions.findOne()
            assert typeof t.fundId is 'number'
            assert.equal t.fundId, 4

          it 'should have fundName', ->
            t = Apollos.transactions.findOne()
            assert typeof t.fundName is 'string'
            assert.equal t.fundName, '<NAME>'

          it 'should have fundAmount', ->
            t = Apollos.transactions.findOne()
            assert typeof t.fundAmount is 'number'
            assert.equal t.fundAmount, 5

          it 'should have transactionCode', ->
            t = Apollos.transactions.findOne()
            assert typeof t.transactionCode is 'number'
            assert.equal t.transactionCode, 6

          it 'should have totalAmount', ->
            t = Apollos.transactions.findOne()
            assert typeof t.totalAmount is 'number'
            assert.equal t.totalAmount, 7

          it 'should have name', ->
            t = Apollos.transactions.findOne()
            assert typeof t.name is 'string'
            assert.equal t.name, '<NAME>'

          it 'should have source', ->
            t = Apollos.transactions.findOne()
            assert typeof t.source is 'string'
            assert.equal t.source, 'Website'

          it 'should have accountMask', ->
            t = Apollos.transactions.findOne()
            assert typeof t.accountMask is 'string'
            assert.equal t.accountMask, 'Mr. Mask'

          it 'should have currencyType', ->
            t = Apollos.transactions.findOne()
            assert typeof t.currencyType is 'string'
            assert.equal t.currencyType, 'ACH'

          it 'should have creditCardtype', ->
            t = Apollos.transactions.findOne()
            assert typeof t.creditCardType is 'string'
            assert.equal t.creditCardType, 'Visa'

          it 'should have submittedDate', ->
            t = Apollos.transactions.findOne()
            assert typeof t.submittedDate is 'object'
            assert.equal t.submittedDate.toDateString, (new Date("01-01-2000 UTC").toDateString())

          it 'should have processedDate', ->
            t = Apollos.transactions.findOne()
            assert typeof t.processedDate is 'object'
            assert.equal t.processedDate.toDateString, (new Date("01-02-2000 UTC").toDateString())<commit_msg>fix transaction tests<commit_after>MochaWeb?.testOnly ->

  assert = chai.assert

  describe 'Apollos', ->
    describe 'transactions', ->

      if Meteor.isServer

        before ->
          props =
            transactionId: 1
            scheduledTransactionId: 2
            personAliasId: 3
            fundId: 4
            fundName: 'Meow Fund'
            fundAmount: 5
            transactionCode: '6'
            totalAmount: 7
            name: '<NAME>'
            source: 'Website'
            accountMask: 'Mr. Mask'
            currencyType: 'ACH'
            creditCardType: 'Visa'
            submittedDate: new Date("01-01-2000 UTC")
            processedDate: new Date("01-02-2000 UTC")

          Apollos.transactions.insert props

        it 'should exist', ->
          assert typeof Apollos.transactions is 'object'

        it 'should have transactionId', ->
          t = Apollos.transactions.findOne()
          assert typeof t.transactionId is 'number'
          assert.equal t.transactionId, 1

        it 'should have scheduledTransactionId', ->
          t = Apollos.transactions.findOne()
          assert typeof t.scheduledTransactionId is 'number'
          assert.equal t.scheduledTransactionId, 2

        it 'should have personAliasId', ->
          t = Apollos.transactions.findOne()
          assert typeof t.personAliasId is 'number'
          assert.equal t.personAliasId, 3

        it 'should have fundId', ->
          t = Apollos.transactions.findOne()
          assert typeof t.fundId is 'number'
          assert.equal t.fundId, 4

        it 'should have fundName', ->
          t = Apollos.transactions.findOne()
          assert typeof t.fundName is 'string'
          assert.equal t.fundName, 'Meow Fund'

        it 'should have fundAmount', ->
          t = Apollos.transactions.findOne()
          assert typeof t.fundAmount is 'number'
          assert.equal t.fundAmount, 5

        it 'should have transactionCode', ->
          t = Apollos.transactions.findOne()
          assert typeof t.transactionCode is 'string'
          assert.equal t.transactionCode, '6'

        it 'should have totalAmount', ->
          t = Apollos.transactions.findOne()
          assert typeof t.totalAmount is 'number'
          assert.equal t.totalAmount, 7

        it 'should have name', ->
          t = Apollos.transactions.findOne()
          assert typeof t.name is 'string'
          assert.equal t.name, 'This happened'

        it 'should have source', ->
          t = Apollos.transactions.findOne()
          assert typeof t.source is 'string'
          assert.equal t.source, 'Website'

        it 'should have accountMask', ->
          t = Apollos.transactions.findOne()
          assert typeof t.accountMask is 'string'
          assert.equal t.accountMask, '<NAME>'

        it 'should have currencyType', ->
          t = Apollos.transactions.findOne()
          assert typeof t.currencyType is 'string'
          assert.equal t.currencyType, 'ACH'

        it 'should have creditCardtype', ->
          t = Apollos.transactions.findOne()
          assert typeof t.creditCardType is 'string'
          assert.equal t.creditCardType, 'Visa'

        it 'should have submittedDate', ->
          t = Apollos.transactions.findOne()
          assert typeof t.submittedDate is 'object'
          assert.equal t.submittedDate.toDateString(), (new Date("01-01-2000 UTC").toDateString())

        it 'should have processedDate', ->
          t = Apollos.transactions.findOne()
          assert typeof t.processedDate is 'object'
          assert.equal t.processedDate.toDateString(), (new Date("01-02-2000 UTC").toDateString())
{'fraction_non_alphanumeric': 0.09649711448127768, 'fraction_numerical': 0.012347335928063348, 'mean_word_length': 1.8291571753986333, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 49, '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': '2754310', 'n_tokens_mistral': 2087, 'n_tokens_neox': 1966, 'n_words': 545}