Revert bottomVisible() test

This commit is contained in:
Oscar
2018-01-31 19:44:46 +00:00
parent 439101197b
commit 9ef0459e71

View File

@ -1,29 +1,12 @@
const test = require('tape');
// const bottomVisible = require('./bottomVisible.js');
// Make the fake properties used by the function
const document = {
documentElement: {
clientHeight: 1080,
scrollHeight: 1080
}
};
const window = {
scrollY: 2160
}
// Override the function to use these fake properties
const bottomVisible = () =>
document.documentElement.clientHeight + window.scrollY >=
(document.documentElement.scrollHeight || document.documentElement.clientHeight);
const bottomVisible = require('./bottomVisible.js');
test('Testing bottomVisible', (t) => {
//For more information on all the methods supported by tape
//Please go to https://github.com/substack/tape
t.true(typeof bottomVisible === 'function', 'bottomVisible is a Function');
//t.deepEqual(bottomVisible(args..), 'Expected');
t.true(bottomVisible(), 'Produces the correct result');
//t.equal(bottomVisible(args..), 'Expected');
//t.false(bottomVisible(args..), 'Expected');
//t.throws(bottomVisible(args..), 'Expected');
t.end();