Your AlertView has clipToBounds
ticked. Thats the reason why you dont see shadow added to AlertView
. Uncheck it to work properly
O/P with clipToBounds
ticked


**O/P after unchecking ClipToBounds **

EDIT:
Though am not sure, the IBInspectable
you set up for properties like Shadow Radius might not be set up correctly, please try setting shadow programmatically
self.alertView.layer.shadowRadius = 3
self.alertView.layer.shadowOffset = CGSize(width: 2, height: 4)
self.alertView.layer.shadowOpacity = 2
self.alertView.layer.shadowColor = UIColor.black.cgColor
If this works then you can solve the issue with IBInspectables of yours