!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/usr/local/lib/node_modules/rtail/node_modules/blob/test/   drwxr-xr-x
Free 13.2 GB of 57.97 GB (22.77%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     index.js (3.05 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
var Blob = require('../');
var expect = require('expect.js');

describe('blob', function() {
  if (!Blob) {
    it('should not have a blob or a blob builder in the global namespace, or blob should not be a constructor function if the module exports false', function() {
      try {
        var ab = (new Uint8Array(5)).buffer;
        global.Blob([ab]);
        expect().fail('Blob shouldn\'t be constructable');
      } catch (e) {}

      var BlobBuilder = global.BlobBuilder
        || global.WebKitBlobBuilder
        || global.MSBlobBuilder
        || global.MozBlobBuilder;
      expect(BlobBuilder).to.be(undefined);
    });
  } else {
    it('should encode a proper sized blob when given a string argument', function() {
      var b = new Blob(['hi']);
      expect(b.size).to.be(2);
    });

    it('should encode a blob with proper size when given two strings as arguments', function() {
      var b = new Blob(['hi', 'hello']);
      expect(b.size).to.be(7);
    });

    it('should encode arraybuffers with right content', function(done) {
      var ary = new Uint8Array(5);
      for (var i = 0; i < 5; i++) ary[i] = i;
      var b = new Blob([ary.buffer]);
      var fr = new FileReader();
      fr.onload = function() {
        var newAry = new Uint8Array(this.result);
        for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i);
        done();
      };
      fr.readAsArrayBuffer(b);
    });

    it('should encode typed arrays with right content', function(done) {
      var ary = new Uint8Array(5);
      for (var i = 0; i < 5; i++) ary[i] = i;
      var b = new Blob([ary]);
      var fr = new FileReader();
      fr.onload = function() {
        var newAry = new Uint8Array(this.result);
        for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i);
        done();
      };
      fr.readAsArrayBuffer(b);
    });

    it('should encode sliced typed arrays with right content', function(done) {
      var ary = new Uint8Array(5);
      for (var i = 0; i < 5; i++) ary[i] = i;
      var b = new Blob([ary.subarray(2)]);
      var fr = new FileReader();
      fr.onload = function() {
        var newAry = new Uint8Array(this.result);
        for (var i = 0; i < 3; i++) expect(newAry[i]).to.be(i + 2);
        done();
      };
      fr.readAsArrayBuffer(b);
    });

    it('should encode with blobs', function(done) {
      var ary = new Uint8Array(5);
      for (var i = 0; i < 5; i++) ary[i] = i;
      var b = new Blob([new Blob([ary.buffer])]);
      var fr = new FileReader();
      fr.onload = function() {
        var newAry = new Uint8Array(this.result);
        for (var i = 0; i < 5; i++) expect(newAry[i]).to.be(i);
        done();
      };
      fr.readAsArrayBuffer(b);
    });

    it('should enode mixed contents to right size', function() {
      var ary = new Uint8Array(5);
      for (var i = 0; i < 5; i++) ary[i] = i;
      var b = new Blob([ary.buffer, 'hello']);
      expect(b.size).to.be(10);
    });

    it('should accept mime type', function() {
      var b = new Blob(['hi', 'hello'], { type: 'text/html' });
      expect(b.type).to.be('text/html');
    });
  }
});

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0038 ]--