import { multiply } from '../';
import { strictEqual } from 'assert';

describe('multiply', () => {
  it('returns 0 when either argument is 0', () => {
    strictEqual(multiply(0, 2), 0);
    strictEqual(multiply(4, 0), 0);
  });

  it('returns the value of one number if the other is 1', () => {
    strictEqual(multiply(1, 8), 8);
    strictEqual(multiply(5, 1), 5);
  });

  it('is commutative', () => {
    strictEqual(multiply(2, 4), multiply(4, 2));
  });

  it('returns the product of the two numbers', () => {
    strictEqual(multiply(11, 9), 99);
  });

  it('handles negative numbers', () => {
    strictEqual(multiply(-2, 2), -4);
    strictEqual(multiply(2, -2), -4);
    strictEqual(multiply(-2, -2), 4);
  });
});

@@ -4,20 +4,20 @@
 ort 
-%7B multiply %7D
+VueCacheData
  fro
@@ -67,655 +67,661 @@
 t';%0A
-%0Adescribe('multiply', () =%3E %7B%0A  it('returns 0 when either argument is 0', () =%3E %7B%0A    strictEqual(multiply(0, 2), 0);%0A    strictEqual(multiply(4, 0), 0);%0A  %7D);%0A%0A  it('returns the value of one number if the other is 1', () =%3E
+import Vue from 'vue'%0A%0Adescribe('VueCacheData', () =%3E %7B%0A  it('normal', (done) =%3E %7B%0A    let AppCache = new VueCacheData()%0A%0A    let defaultVal = %5B'NJ', 'JX'%5D%0A    let fetchedVal = %5B'BJ', 'SH', 'SZ', 'GZ'%5D%0A%0A    AppCache.add('stockList', () =%3E defaultVal, function (onSucc)
  %7B%0A    
+ 
-strictEqual(multiply(1, 8), 8);%0A    strictEqual(multiply(5, 1), 5);%0A
+ setTimeout(function () %7B%0A        return onSucc(fetchedVal)%0A      %7D, 0)%0A 
   
+ 
 %7D)
-;
 %0A%0A  
+ 
-it('is commutative', () =%3E %7B%0A    strictEqual(multiply(2, 4), multiply(4, 2));%0A  %7D);%0A%0A  it('returns the product of the two numbers', () =%3E %7B%0A    strictEqual(multiply(11, 9), 99);%0A
+ AppCache.init()%0A%0A    let vm = new Vue(%7B%0A      computed: %7B%0A        stockList () %7B%0A          return AppCache.vm.stockList%0A        %7D%0A      %7D%0A  
   %7D)
-;
 %0A%0A  
-it('handles negative numbers', () =%3E %7B%0A    strictEqual(multiply(-2, 2), -4);%0A    strictEqual(multiply(2, -2), -4);%0A    strictEqual(multiply(-2, -2), 4);
+  vm.$watch('stockList', function () %7B%0A      strictEqual(vm.stockList, fetchedVal)%0A      done()%0A    %7D)%0A%0A    strictEqual(vm.stockList, defaultVal)
 %0A  %7D

add test