1
0

index.js 487 B

12345678910111213141516171819202122
  1. import test from 'ava';
  2. import Hydrawise from '../lib/hydrawise';
  3. const hydrawise = new Hydrawise('53DC-7E24-07E8-CD7D');
  4. test('Customer Details', t => {
  5. return hydrawise.customerdetails().then(data => {
  6. if (data.error_msg) {
  7. t.fail(`Error: ${data.error_msg}`);
  8. }
  9. t.pass();
  10. });
  11. });
  12. test('Status Schedule', t => {
  13. return hydrawise.statusschedule().then(data => {
  14. if (data.error_msg) {
  15. t.fail(`Error: ${data.error_msg}`);
  16. }
  17. t.pass();
  18. });
  19. });