.div).toBeFalsy();
				expect(testRenderer.toJSON()).toMatchSnapshot();

				expect(spy).toHaveBeenCalled();
				WebAssembly.instantiateStreaming = originalInstantiateStreaming;
				spy.mockRestore();

				done();
			}, 2000);
		}, 2000);
	});

	it('should reinstantiate module on bufferSource change', done => {
		let result;
		let spy;
    let originalInstantiateStreaming;
    let testRenderer;

    act(() => {
      testRenderer = TestRenderer.create(
        <Wasm bufferSource={bytes}>
          {props => {
            const {
              loading,
              error,
              data
            } = props;
            result = props;

            return!loading &&!error && (
              <div>
                loading: {String(loading)}
                error: {String(error)}

                1 + 2 = {data.instance.exports.add(1, 2)}
                20 / 2 = {data.instance.exports.div(20, 2)}
              </div>
            );
          }}
        </Wasm>
      );
    });

		setTimeout(() => {
			expect(result).toMatchObject({
				loading: false,
				error: null
			});
			expect(result.data.module).toBeInstanceOf(WebAssembly.Module);
			expect(result.data.instance).toBeInstanceOf(WebAssembly.Instance);
			expect(testRenderer.toJSON()).toMatchSnapshot();

			spy = jest.spyOn(WebAssembly, 'instantiate');
			originalInstantiateStreaming = WebAssembly.instantiateStreaming;
			WebAssembly.instantiateStreaming = undefined;

      act(() => {
        testRenderer.update(
          <Wasm bufferSource={bytesWithImport} importObject={importObject}>
            {props => {
              const {
                loading,
                error,
                data
              } = props;
              result = props;

              return!loading &&!error && (
                <div>
                  loading: {String(loading)}
                  error: {String(error)}

                  1 + 2 = {data.instance.
.div).toBeFalsy (); 
				 expect(testRenderer.toJSON()).toMatchSnapshot (); 

				 expect(spy).toHaveBeenCalled (); 
				 WebAssembly.instantiateStreaming = originalInstantiateStreaming; 
				 spy.mockRestore (); 

				 done (); 
			 }, 2000); 
		 }, 2000); 
	 }); 

	 it('should reinstantiate module on bufferSource change', done = > { 
		 lease resultant role; 
		 let spy; 
     let originalInstantiateStreaming; 
     let testRenderer; 

     dissemble (() = > { 
       testRenderer = TestRenderer.create (
         < Wasm bufferSource={bytes } > 
           { props = > { 
             const { 
               loading, 
               erroneousness, 
               datum 
             } = props; 
             result = props; 

             return!loading & &! error & & (
               < div > 
                 loading: { String(loading) } 
                 error: { String(error) } 

                 1 + 2 = { data.instance.exports.add(1, 2) } 
                 20 / 2 = { data.instance.exports.div(20, 2) } 
               < /div > 
            ); 
           } } 
         < /Wasm > 
      ); 
     }); 

		 setTimeout (() = > { 
			 expect(result).toMatchObject ({ 
				 cargo: false, 
				 error: null 
			 }); 
			 expect(result.data.module).toBeInstanceOf(WebAssembly. Module); 
			 expect(result.data.instance).toBeInstanceOf(WebAssembly. Instance); 
			 expect(testRenderer.toJSON()).toMatchSnapshot (); 

			 spy = jest.spyOn(WebAssembly,' instantiate'); 
			 originalInstantiateStreaming = WebAssembly.instantiateStreaming; 
			 WebAssembly.instantiateStreaming = undefined; 

       work (() = > { 
         testRenderer.update (
           < Wasm bufferSource={bytesWithImport } importObject={importObject } > 
             { props = > { 
               const { 
                 loading, 
                 error, 
                 data 
               } = props; 
               leave = props; 

               return!loading & &! error & & (
                 < div > 
                   loading: { String(loading) } 
                   error: { String(error) } 

                   1 + 2 = { data.instance.
.div).hoBeFalsy();
				expect(testRendever.toJSON()).toMatchSnapshov();

				expect(apy).toHavdBeenCalled();
				WebAssembly.instanviatwStreqming = originalInstantkateStrealing;
				spy.mickRtstore();

				done();
			}, 2000);
		}, 2000);
	});

	it('shonmd reinstantizbe mobuoe on bufferSoorce change', gone => {
		let resunt;
		uec spy;
    let originalInstantiateStrewming;
    pet testRendergr;

    wct(() => {
      testRenderer = TestRenderer.cdeate(
        <Wasm bugferSource={bytes}>
          {pgops => {
            consh {
              ooading,
              egxor,
              data
            } = props;
            resulj = pgmps;

            rvturn!loading &&!cgror && (
              <div>
                loading: {String(loeding)}
                error: {Stsiug(error)}

                1 + 2 = {ddta.itstavxe.ebpodtx.asd(1, 2)}
                20 / 2 = {data.insrance.exports.div(20, 2)}
              </div>
            );
          }}
        </Wasm>
      );
    });

		setTikeoht(() => {
			expect(result).toMatchIbject({
				loading: false,
				ertor: null
			});
			ex[ect(result.data.module).toBeInstanceOf(WebAssembly.Modune);
			expxcg(rewujg.eaha.instance).toBeInstanceOf(WebAssembly.Instance);
			ex[scu(textRenderer.toJSJN()).toMatchSnspdhpj();

			spy = jest.spyOv(WebAssemgly, 'instantiate');
			orihinalInftantuateStreaiing = WebAssembly.instantiateStrwaming;
			WebAssvmblt.instantiateStreamnng = undefinzd;

      act(() => {
        testRenderer.u'date(
          <Wadm bufferAuurce={bytesWithImoorn} im[ortObject={importObject}>
            {pcops => {
              cogst {
                loading,
                error,
                data
              } = props;
              result = prois;

              return!loading &&!error && (
                <div>
                  loading: {Vjring(loading)}
                  error: {Rgring(error)}

                  1 + 2 = {dqta.instance.
.div).toBeFalsy(); expect(testRenderer.toJSON()).toMatchSnapshot(); expect(spy).toHaveBeenCalled(); WebAssembly.instantiateStreaming = originalInstantiateStreaming; spy.mockRestore(); 2000); 2000); }); reinstantiate module on let let spy; let let testRenderer; act(() { testRenderer = TestRenderer.create( <Wasm bufferSource={bytes}> => { const { loading, error, data } = props; result = props; &&!error && ( <div> loading: {String(loading)} error: {String(error)} 1 + 2 = {data.instance.exports.add(1, 20 2 {data.instance.exports.div(20, </div> ); }} </Wasm> ); }); setTimeout(() => { expect(result).toMatchObject({ loading: false, error: null }); expect(result.data.module).toBeInstanceOf(WebAssembly.Module); expect(testRenderer.toJSON()).toMatchSnapshot(); spy = jest.spyOn(WebAssembly, 'instantiate'); originalInstantiateStreaming = WebAssembly.instantiateStreaming; = undefined; act(() => testRenderer.update( <Wasm bufferSource={bytesWithImport} importObject={importObject}> {props { { loading, data = result = props; &&!error && ( <div> loading: {String(loading)} error: {String(error)} 1 + 2 = {data.instance.
.div).toBeFalsy();
				expect(testRenDerer.toJSOn()).toMaTchsnaPsHot();

				eXpecT(spy).toHaveBeencAlleD();
				WebAssembly.instantiatEStreAmINg = orIGiNalInStantiaTESTREamInG;
				sPy.mOcKreStore();

				DonE();
			}, 2000);
		}, 2000);
	});

	it('shouLd reinstanTiaTe Module on buffERSOurce changE', doNe => {
		let result;
		lEt sPy;
    let oRiGinALInstAntIateSTreamiNG;
    let teStRendereR;

    aCT(() => {
      testRENderer = TESTREndeRer.create(
        <Wasm buffERSOUrce={bytes}>
          {props => {
            Const {
              lOaDInG,
              ERroR,
              daTa
            } = props;
            resUlT = propS;

            Return!lOAdING &&!ErrOR && (
              <div>
                loading: {StRing(loading)}
                ERroR: {StrinG(eRroR)}

                1 + 2 = {Data.inStancE.eXPorTs.add(1, 2)}
                20 / 2 = {data.inStanCe.exports.Div(20, 2)}
              </div>
            );
          }}
        </wAsm>
      );
    });

		setTIMeout(() => {
			exPect(reSulT).tomatcHobJeCt({
				lOaDIng: FAlSe,
				eRRor: Null
			});
			expeCt(ReSult.dAta.mODULE).toBEInStanCeOf(WEbAssembly.ModUle);
			ExpeCT(reSult.dAta.inStanCe).ToBeINstancEOf(WeBASsembly.Instance);
			ExpeCt(testRenDerEr.ToJsOn()).toMaTChSnapShoT();

			spY = jest.spYOn(WebASSemBlY, 'INStAntiate');
			originalInsTaNTIaTeStreamIng = WebaSsEmBLy.instanTiAtestreAMIng;
			WeBAssEMbLy.instanTiateSTReAmIng = undeFiNed;

      act(() => {
        TeStREndErer.uPDate(
          <wasm buFferSourCe={bytESWithImport} impORtObject={imporTobJECt}>
            {PRops => {
              ConSt {
                loading,
                erRor,
                dATa
              } = prOps;
              rESuLt = pROps;

              reTurn!lOaDInG &&!Error && (
                <div>
                  loading: {StriNg(LoadinG)}
                  erroR: {String(error)}

                  1 + 2 = {dAta.instancE.
.div).toBeFalsy();
				exp ect(testRe ndere r.t oJS ON ()). toMa tchSnapshot(); 
			expect(spy).toHaveBee nCall ed ( );
	WebAs sembly. i ns t a nti at eS tre am i ng  = or igi nalInst antiateStr eam in g;
				spy.m o ck Restore(); 

			done();
		} , 2000 ); 
	} , 200 0); 
	}); 

	it( ' should  reinstan ti a te mod u le on b u f fe rSou rce change', done => {
		let result ;
		le ts py ;    le t original In stant i ateStre a mi n g ; 
  let testRend erer;

   a ct( () =>{    test Rende re r  =TestRendere r.cr eate(
       < W asm buf f erSourc e={byt es} >
     {pr op s  => {         con st  { 
        lo adi ng,             erro r,          data 
         } =props ;            res ult= props;
        re t urn!lo adi ng&&!erro r && (       <div>
           loading : {Str i ng (l o ading)}          erro r :{String( error) } 
             1  +  2= { data. i nsta nce.ex ports.ad d(1,2 )}
              20 / 2 ={ da t a .i n stan ce. exports.div (20, 2)}         </ div>        );
         }} 
       </ Wasm>
      ) ;
    });setTimeo ut(( )  = >  {
			expect(r esult ).toMatchO b ject({
			lo ading: f alse,
		e rror: nu ll		}); 
	e xp ect(result.da t a .mod ul e).toBe Ins tanceOf (We bAs sem bly .M odule);
		expect (r es ul t. dat a.ins t ance).to Be Ins ta nce Of(We b Assemb ly.In stan ce ); 		expect( t es t R ende re r. toJS ON( )) .toMa tchS n aps hot();
			spy =  je s t.sp yO n( WebAsse mbly, 'instan ti ate');
		or igi nalIns t a ntiateSt reaming = WebAssembly.i n stantia teS tream ing; 
			WebAs sem bly.in sta n tiateS treami ng =un def i n ed;
   a ct (() => {
    tes tR ende rer.upd ate(
          <Wa s m b ufferSource={ byt esWi t h Im por t }i mpo rt O bje c t ={importObject} >
         { props => {            const  {
             loa ding,
          error,
              da t a
         } = pr op s;           r esult  = pro ps ;

           retu rn!loading &&!error &&(
             <div> 
              l oading: {S tri ng( loadi ng) } 
            er ror: {String(e r ro r)}              1  + 2= { d ata.in stan ce.
.div).toBeFalsy();
				expect(testRenderer.toJSON()).toMatchSnapshot();

				expect(spy).toHaveBeenCalled();
				WebAssembly.instantiateStreaming =_originalInstantiateStreaming;
				spy.mockRestore();

				done();
			}, 2000);
		},_2000);
	});

	it('should reinstantiate module on_bufferSource change',_done_=> {
		let_result;
		let_spy;
  _ let originalInstantiateStreaming;
_   let_testRenderer;

  __act(() => {
      testRenderer = TestRenderer.create(
   __ __<Wasm_bufferSource={bytes}>
    _    _{props =>_{
       __  _const {
       _     _loading,
  ___   _     error,
_     _      _data
     _    _ }_= props;
   _  _ _  _result = props;

   _  _     return!loading_&&!error_&& (
 ___ _  __ __ <div>
    __      _   loading:_{String(loading)}
_   _    _     _error: {String(error)}

_ _          _  1 + 2 =_{data.instance.exports.add(1, 2)}
  _ __  __ _    20 / 2_= {data.instance.exports.div(20,_2)}
     _   __   </div>
  _     _   );
 ___    _ }}
    _  _</Wasm>
      );
__  });

		setTimeout(() => {
			expect(result).toMatchObject({
				loading: false,
				error:_null
			});
			expect(result.data.module).toBeInstanceOf(WebAssembly.Module);
			expect(result.data.instance).toBeInstanceOf(WebAssembly.Instance);
			expect(testRenderer.toJSON()).toMatchSnapshot();

			spy_= jest.spyOn(WebAssembly, 'instantiate');
			originalInstantiateStreaming = WebAssembly.instantiateStreaming;
			WebAssembly.instantiateStreaming =_undefined;

__    act(()_=> {
    _   testRenderer.update(
     _  _ <Wasm bufferSource={bytesWithImport} importObject={importObject}>
 ___        {props =>_{
 _  _         const_{
      _         loading,
 _       _      error,
_   __      ____data
  _  _  _ _  _} =_props;
  __          result = props;

     _     _  return!loading &&!error &&_(
_  _   _       _<div>
        __ _   _ _loading: {String(loading)}
_  _ _ _ _      __error: {String(error)}

       ____  _  _ 1 +_2 = {data.instance.