| 1 | // Copyright © SixtyFPS GmbH <info@slint.dev> |
| 2 | // SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0 |
| 3 | |
| 4 | TestCase := Rectangle { |
| 5 | property<float> t1: log(4.0, 2); |
| 6 | property<float> t2: log(64, 4.0); |
| 7 | } |
| 8 | /* |
| 9 | ```cpp |
| 10 | auto handle = TestCase::create(); |
| 11 | const TestCase &instance = *handle; |
| 12 | assert_eq(instance.get_t1(), 2.0); |
| 13 | assert_eq(instance.get_t2(), 3.0); |
| 14 | ``` |
| 15 | |
| 16 | ```rust |
| 17 | let instance = TestCase::new().unwrap(); |
| 18 | assert_eq!(instance.get_t1(), 2.0); |
| 19 | assert_eq!(instance.get_t2(), 3.0); |
| 20 | ``` |
| 21 | |
| 22 | ```js |
| 23 | var instance = new slint.TestCase({}); |
| 24 | assert.equal(instance.t1, 2); |
| 25 | assert.equal(instance.t2, 3); |
| 26 | ``` |
| 27 | */ |
| 28 | |