docs: function _addAttribute() {
    var attributeDictionary = arguments[0];
  
    var attribute = null;
    var name = null;
  
    if (arguments.length === 2) {
      attribute = arguments[1];
    } else {
      attribute = arguments[1];
      name = arguments[2];
    }
  
    expect(attribute).to.be.an(
      'object',
      'Invalid argument type when adding an attribute ' + (name ? 'called "' +
      name + '" ' : '') + 'in an AttributeDictionary (it has to be an object)'
    );
  
    if (name) {
      if (attribute.name) {
        expect(attribute.name).to.equal(
          name,
          'Invalid argument "name" when adding an attribute called "' +
          attribute.name + '" in an AttributeDictionary (the name given in ' +
          'argument and the name given in the attribute object should be equal)'
        );
      } else {
        attribute.name = name;
      }
    }
  
    if (!(attribute instanceof Attribute)) {
      attribute = Attribute.resolve(attribute);
    }
  
    expect(attribute.constructor).to.not.equal(
      Attribute,
      'Invalid attribute "' + attribute.name + '". Attribute is an abstract ' +
      'class and cannot be directly instantiated and added in an ' +
      'AttributeDictionary'
    );
  
    expect(attributeDictionary).to.not.have.ownProperty(
      attribute.name,
      'Duplicated attribute name "' + attribute.name + '"'
    );
  
    Object.defineProperty(attributeDictionary, attribute.name, {
      value: attribute,
      enumerable: true,
      writable: false,
      configurable: false
    });
  }