!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)

/var/www/html/queuepro/node_modules/quill-delta/test/   drwxrwxr-x
Free 13.21 GB of 57.97 GB (22.79%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     attributes.js (3.24 KB)      -rwxrwxr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
var op = require('../lib/op');


describe('attributes', function () {
  describe('compose()', function () {
    var attributes = { bold: true, color: 'red' };

    it('left is undefined', function () {
      expect(op.attributes.compose(undefined, attributes)).toEqual(attributes);
    });

    it('right is undefined', function () {
      expect(op.attributes.compose(attributes, undefined)).toEqual(attributes);
    });

    it('both are undefined', function () {
      expect(op.attributes.compose(undefined, undefined)).toBe(undefined);
    });

    it('missing', function () {
      expect(op.attributes.compose(attributes, { italic: true })).toEqual({
        bold: true,
        italic: true,
        color: 'red'
      });
    });

    it('overwrite', function () {
      expect(op.attributes.compose(attributes, { bold: false, color: 'blue' })).toEqual({
        bold: false,
        color: 'blue'
      });
    });

    it('remove', function () {
      expect(op.attributes.compose(attributes, { bold: null })).toEqual({
        color: 'red'
      });
    });

    it('remove to none', function () {
      expect(op.attributes.compose(attributes, { bold: null, color: null })).toEqual(undefined);
    });

    it('remove missing', function () {
      expect(op.attributes.compose(attributes, { italic: null })).toEqual(attributes);
    });
  });

  describe('diff()', function () {
    var format = { bold: true, color: 'red' };

    it('left is undefined', function () {
      expect(op.attributes.diff(undefined, format)).toEqual(format);
    });

    it('right is undefined', function () {
      var expected = { bold: null, color: null };
      expect(op.attributes.diff(format, undefined)).toEqual(expected);
    });

    it('same format', function () {
      expect(op.attributes.diff(format, format)).toEqual(undefined);
    });

    it('add format', function () {
      var added = { bold: true, italic: true, color: 'red' };
      var expected = { italic: true };
      expect(op.attributes.diff(format, added)).toEqual(expected);
    });

    it('remove format', function () {
      var removed = { bold: true };
      var expected = { color: null };
      expect(op.attributes.diff(format, removed)).toEqual(expected);
    });

    it('overwrite format', function () {
      var overwritten = { bold: true, color: 'blue' };
      var expected = { color: 'blue' };
      expect(op.attributes.diff(format, overwritten)).toEqual(expected);
    });
  });

  describe('transform()', function () {
    var left = { bold: true, color: 'red', font: null };
    var right = { color: 'blue', font: 'serif', italic: true };

    it('left is undefined', function () {
      expect(op.attributes.transform(undefined, left, false)).toEqual(left);
    });

    it('right is undefined', function () {
      expect(op.attributes.transform(left, undefined, false)).toEqual(undefined);
    });

    it('both are undefined', function () {
      expect(op.attributes.transform(undefined, undefined, false)).toEqual(undefined);
    });

    it('with priority', function () {
      expect(op.attributes.transform(left, right, true)).toEqual({
        italic: true
      });
    });

    it('without priority', function () {
      expect(op.attributes.transform(left, right, false)).toEqual(right);
    });
  });
});

:: 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.0048 ]--