: 100px;
  height: 100px;
  background: red;
}

.abs {
  position: absolute;
  background: green;
}

.child {
  width: 100px;
  height: 100px;
  padding-right: 50%;
}
</style>
<p>Test passes if there is a filled green square.</p>
<div class="container">
  <div class="abs">
    <div class="child"></div>
  </div>
</div>
