DateTime: Enhance docs related to epoch times.
Fixes
@@ -27,7 +27,7 @@ also be used by other libraries programmatically.
= Terminology =
-In the context of this library, ``date`` and ``time`` generally have following
+In the context of this library, ``date`` and ``time`` generally have the following
meanings:
- ``date``: An entity with both date and time components but without any
@@ -43,7 +43,7 @@ objects match ``date`` and ``time`` as defined by this library.
= Date formats =
-Dates can given to and received from keywords in `timestamp`, `custom
+Dates can be given to and received from keywords in `timestamp`, `custom
timestamp`, `Python datetime` and `epoch time` formats. These formats are
discussed thoroughly in subsequent sections.
@@ -119,17 +119,19 @@ Examples:
Epoch time is the time in seconds since the
[http://en.wikipedia.org/wiki/Unix_time|UNIX epoch] i.e. 00:00:00.000 (UTC)
-1 January 1970. To give a date in epoch time, it must be given as a number
-(integer or float), not as a string. To return a date in epoch time,
+January 1, 1970. To give a date as an epoch time, it must be given as a number
+(integer or float), not as a string. To return a date as an epoch time,
it is possible to use ``epoch`` value with ``result_format`` argument.
-Epoch time is returned as a floating point number.
+Epoch times are returned as floating point numbers.
-Notice that epoch time itself is independent on timezones and thus same
-around the world at a certain time. What local time a certain epoch time
-matches obviously then depends on the timezone. For example, examples below
-were tested in Finland but verifications would fail on other timezones.
+Notice that epoch times are independent on time zones and thus same
+around the world at a certain time. For example, epoch times returned
+by `Get Current Date` are not affected by the ``time_zone`` argument.
+What local time a certain epoch time matches then depends on the time zone.
+
+Following examples demonstrate using epoch times. They are tested in Finland,
+and due to the reasons explained above they would fail on other time zones.
-Examples:
| ${date} = | Convert Date | ${1000000000} |
| Should Be Equal | ${date} | 2001-09-09 04:46:40.000 |
| ${date} = | Convert Date | 2014-06-12 13:27:59.279 | epoch |
@@ -309,6 +311,7 @@ def get_current_date(time_zone='local', increment=0,
Arguments:
- ``time_zone:`` Get the current time on this time zone. Currently only
``local`` (default) and ``UTC`` are supported.
+ Has no effect if date is returned as an `epoch time`.
- ``increment:`` Optional time increment to add to the returned date in
one of the supported `time formats`. Can be negative.
- ``result_format:`` Format of the returned date (see `date formats`).
