anchor.diff:        invocations = [];
         document.body.append(div);
         customElementsTakeRecords();
  -      expect(invocations, ['entered'],
  -          reason: 'the entered callback should be invoked when inserted into a '
  +      expect(invocations, ['attached'],
  +          reason: 'the attached callback should be invoked when inserted into a '
             'document with a view as part of a subtree');
       });
     });
  
positive.code:       upgradeCustomElements(s);
  
        expect(invocations, ['created'],
            reason: 'the entered callback should not be invoked when entering a '
            'Shadow DOM subtree not in the document');
      });
  
      test('Leaves Shadow DOM that is not in a document', () {
        s.innerHtml = '';
        expect(invocations, [],
            reason: 'the left callback should not be invoked when leaving a '
            'Shadow DOM subtree not in the document');
      });
  
  
negative.code:     invocations.add('created');
    }
  
    void attached() {
      invocations.add('attached');
    }
  
    void enteredView() {
      // Deprecated name. Should never be called since we override "attached".
      invocations.add('enteredView');
    }
  
    void detached() {
      invocations.add('detached');
    }
  
    void leftView() {
      // Deprecated name. Should never be called since we override "detached".
      invocations.add('leftView');
    }
  
    void attributeChanged(String name, String oldValue, String newValue) {
  