You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
expect(Object.getPrototypeOf(TNSInterfaceNeverAvailableDescendant).toString()).toBe(TNSInterfaceAlwaysAvailable.toString(),"TNSInterfaceNeverAvailable base class should be skipped as it is unavailable");
80
80
});
81
+
82
+
it("Members of a protocol which is unavailable should be skipped",function(){
83
+
expect(Object.getOwnPropertyNames(TNSInterfaceAlwaysAvailable)).not.toContain("staticPropertyFromProtocolNeverAvailable","TNSProtocolNeverAvailable static properties should be skipped as it is unavailable");
84
+
expect(TNSInterfaceAlwaysAvailable.staticMethodFromProtocolNeverAvailable).toBeUndefined("TNSProtocolNeverAvailable static methods should be skipped as it is unavailable");
85
+
expect(Object.getOwnPropertyNames(TNSInterfaceAlwaysAvailable.prototype)).not.toContain("propertyFromProtocolNeverAvailable","TNSProtocolNeverAvailable properties should be skipped as it is unavailable");
86
+
expect(newTNSInterfaceAlwaysAvailable().methodFromProtocolNeverAvailable).toBeUndefined("TNSProtocolNeverAvailable methods should be skipped as it is unavailable");
87
+
});
88
+
89
+
it("Members of a protocol which is available should be present",function(){
90
+
constobj=newTNSInterfaceAlwaysAvailable();
91
+
letexpectedOutput="";
92
+
expect(Object.getOwnPropertyNames(TNSInterfaceAlwaysAvailable.prototype)).toContain("propertyFromProtocolAlwaysAvailable","TNSProtocolAlwaysAvailable properties should be present as it is available");
expect(Object.getOwnPropertyNames(TNSInterfaceAlwaysAvailable)).toContain("staticPropertyFromProtocolAlwaysAvailable","TNSProtocolAlwaysAvailable static properties should be present as it is available");
expect(TNSInterfaceAlwaysAvailable.staticMethodFromProtocolAlwaysAvailable).toBeDefined("TNSProtocolAlwaysAvailable static methods should be present as it is available");
0 commit comments