Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.js 687B

12345678910111213141516171819202122232425262728
  1. 'use strict';
  2. /*jshint asi: true */
  3. var test = require('tap').test
  4. var devnull = require('../');
  5. var tapstream = require('tap-stream')
  6. var numbers = require('./fixtures/number-readable')
  7. test('\npiping without devnull', function (t) {
  8. var data = [];
  9. numbers({ to: 2 })
  10. .on('data', function (d) { data.push(d) })
  11. .on('end', function () {
  12. t.equal(data.length, 3, 'streams 3 numbers')
  13. t.end()
  14. })
  15. })
  16. test('\npiping through devnull', function (t) {
  17. var data = [];
  18. numbers({ to: 2 })
  19. .on('end', function () {
  20. t.equal(data.length, 0, 'streams 0 numbers')
  21. t.end()
  22. })
  23. .pipe(devnull())
  24. .on('data', function (d) { data.push(d) })
  25. })