(self)
| 199 | self.assertEqual(expect, result) |
| 200 | |
| 201 | def test_get(self): |
| 202 | expect = make_expression_graph({ |
| 203 | 'arguments': { |
| 204 | 'date': date_function_expr(1), |
| 205 | 'unit': {'constantValue': DAY}, |
| 206 | 'timeZone': {'constantValue': UTC}, |
| 207 | }, |
| 208 | 'functionName': 'Date.get', |
| 209 | }) |
| 210 | expression = ee.Date(1).get(DAY, UTC) |
| 211 | result = json.loads(expression.serialize()) |
| 212 | self.assertEqual(expect, result) |
| 213 | |
| 214 | expression = ee.Date(1).get(unit=DAY, timeZone=UTC) |
| 215 | result = json.loads(expression.serialize()) |
| 216 | self.assertEqual(expect, result) |
| 217 | |
| 218 | def test_get_fraction(self): |
| 219 | expect = make_expression_graph({ |
nothing calls this directly
no test coverage detected