forked from mirrors/gecko-dev
- Added `--enable-uniffi-fixtures` flag. When set, we will compile in the UniFFI test fixtures into our shared Rust crate and eventually into `libxul`. - Vendoring in the Rust crates needed for `uniffi-bindgen-gecko-js` Differential Revision: https://phabricator.services.mozilla.com/D144467
10 lines
231 B
Python
10 lines
231 B
Python
from geometry import *
|
|
|
|
ln1 = Line(Point(0,0), Point(1,2))
|
|
ln2 = Line(Point(1,1), Point(2,2))
|
|
|
|
assert gradient(ln1) == 2
|
|
assert gradient(ln2) == 1
|
|
|
|
assert intersection(ln1, ln2) == Point(0, 0)
|
|
assert intersection(ln1, ln1) is None
|