Verifies the full function invocation flow.
(self)
| 88 | ee.Function._registerPromoter(old_promoter) |
| 89 | |
| 90 | def test_call(self): |
| 91 | """Verifies the full function invocation flow.""" |
| 92 | old_promoter = ee.Function._promoter |
| 93 | ee.Function._registerPromoter(lambda obj, type_name: [type_name, obj]) |
| 94 | |
| 95 | return_type, return_value = TEST_FUNC.call(42, 13) |
| 96 | self.assertEqual('Image', return_type) |
| 97 | self.assertEqual(TEST_FUNC, return_value.func) |
| 98 | self.assertEqual({ |
| 99 | 'a': ['Image', 42], |
| 100 | 'b': ['Image', 13] |
| 101 | }, return_value.args) |
| 102 | |
| 103 | # Clean up. |
| 104 | ee.Function._registerPromoter(old_promoter) |
| 105 | |
| 106 | def test_to_string(self): |
| 107 | """Verifies function docstring generation.""" |
nothing calls this directly
no test coverage detected