IBM / python-sdk-core

The python-sdk-core repository contains core functionality required by Python code generated by the IBM OpenAPI SDK Generator.
Apache License 2.0
20 stars 27 forks source link

fix: use millisecond precision when marshalling date-time values #86

Closed padamstx closed 3 years ago

padamstx commented 3 years ago

Fixes arf/planning-sdk-squad#2313

This commit makes a minor change to the datetime_to_string function so that it uses millisecond precision when converting a datetime value to a string. This is aligned with the API handbook requiremetns re: the wire format for date-time values. I also added a bunch of tests that are (more or less) similar to the set of tests in the Java and Go cores.

padamstx commented 3 years ago

Looks like all 4 of the builds failed due to me using a feature that is not available in any of the python versions that we currently support. THANKS PYTHON!!! I'll regroup and update this PR.

codecov[bot] commented 3 years ago

Codecov Report

Merging #86 (dd11b92) into master (819e6dd) will not change coverage. The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #86   +/-   ##
=======================================
  Coverage   98.19%   98.19%           
=======================================
  Files          18       18           
  Lines         665      665           
=======================================
  Hits          653      653           
  Misses         12       12           
Impacted Files Coverage Δ
ibm_cloud_sdk_core/utils.py 99.19% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 819e6dd...dd11b92. Read the comment docs.

padamstx commented 3 years ago

Closing this and will open a new PR.