jamesshore / quixote

CSS unit and integration testing
Other
848 stars 45 forks source link

hasClippingOverflow(element) : Missing CSS overflow values #57

Closed claudeG closed 4 years ago

claudeG commented 4 years ago

Hi James !

Got "EnsureException: Unknown overflow property: hidden auto". The problem is in descriptors/element_rendered_edge.js, function hasClippingOverflow(element).

No doubt that you know why. For other readers : overflow-x is free to be different from overflow-y.

The complete set of standard values on one axis is { visible, hidden, clip, scroll, auto, overlay }. 'overlay' is deprecated and Quixote excludes it currently. 'clip' is not supported yet because it could be in the future.

In the first note of https://developer.mozilla.org/en-US/docs/Web/CSS/overflow, we can read: "Setting one axis to visible (the default) while setting the other to a different value results in visible behaving as auto."

So in hasClippingOverflow(element), the complete of values considered in the switch statement should be (more legible in spreadsheet Excel or like. Duplicates are commented)

   case "visible":         /* case "auto hidden": */  /* case "auto clip": */  /* case "auto scroll": */  /* case "auto": */
/* case "hidden auto": */     case "hidden":             case "hidden clip":      case "hidden scroll":      case "hidden auto":
/* case "clip auto": */       case "clip hidden":        case "clip":             case "clip scroll":        case "clip auto":
/* case "scroll auto": */     case "scroll hidden":      case "scroll clip":      case "scroll":             case "scroll auto":
/* case "auto": */            case "auto hidden":        case "auto clip":        case "auto scroll":        case "auto":

For what I understand in the current function code, all these cases return false and only "visible" returns true.

Regards

Claude G.

jamesshore commented 4 years ago

Thanks for the report, Claude. This is fixed and will be in the next release.

claudeG commented 4 years ago

Hi James ! Are you aware about any initiative related to the convertion of CAD-like files to Quixote tests ? Regards Claude

Le jeu. 9 avr. 2020 23:55, James Shore notifications@github.com a écrit :

Thanks for the report, Claude. This is fixed and will be in the next release.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jamesshore/quixote/issues/57#issuecomment-611771743, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCUTPZ67IPTT7GNWW24RG3RLY75DANCNFSM4LVV3OCQ .

jamesshore commented 4 years ago

No, I'm not aware of anything like that.

claudeG commented 4 years ago

While not completely adapted to the specification of UI parts, the parametric draft mode of FreeCad allows to specify geometric constraints very similar to those supported by Quixote. The result is an Xml file. So it would not too difficult to generate test descriptors convertible to Quixote. I see this as something very powerful. But FreeCad will become frustrating very quickly. Need for a dedicated FreeCad plugin. Python development... If you are inspired : )

Le ven. 10 avr. 2020 00:07, James Shore notifications@github.com a écrit :

No, I'm not aware of anything like that.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jamesshore/quixote/issues/57#issuecomment-611776280, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCUTP4GDNZOJVUJXIWWHL3RLZBLVANCNFSM4LVV3OCQ .

jamesshore commented 4 years ago

This is outside of the scope for Quixote.

claudeG commented 4 years ago

Possibly complementary but out of the scope I agree... Nevertheless congratulations for your dev. Regards Claude

Le ven. 10 avr. 2020 00:27, James Shore notifications@github.com a écrit :

This is outside of the scope for Quixote.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/jamesshore/quixote/issues/57#issuecomment-611783597, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACCUTP2NJ7DEXEZBU6AW6ELRLZDW7ANCNFSM4LVV3OCQ .

jamesshore commented 4 years ago

Fixed in v0.14.1.