1414# # with this program; if not, write to the Free Software Foundation, Inc.,
1515# # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
1616
17- library(" git2r" )
17+ library(git2r )
1818
1919# # For debugging
2020sessionInfo()
@@ -31,21 +31,27 @@ stopifnot(identical(print(git_t), git_t))
3131as.POSIXct(1395567947 , origin = " 1970-01-01" , tz = " -03" )
3232
3333# # Test that origin/tz can be passed to as.POSIXct
34- stopifnot(identical(as.POSIXct(git_t , tz = " Europe/Stockholm" , origin = " 1980-02-02" ),
35- as.POSIXct(1395567947 , tz = " Europe/Stockholm" , origin = " 1980-02-02" )))
34+ stopifnot(identical(as.POSIXct(git_t , tz = " Europe/Stockholm" ,
35+ origin = " 1980-02-02" ),
36+ as.POSIXct(1395567947 , tz = " Europe/Stockholm" ,
37+ origin = " 1980-02-02" )))
3638
3739# # Test that origin/tz can be passed to as.character
38- stopifnot(identical(as.character(git_t , tz = " Europe/Stockholm" , origin = " 1980-02-02" ),
40+ stopifnot(identical(as.character(git_t , tz = " Europe/Stockholm" ,
41+ origin = " 1980-02-02" ),
3942 " 2024-04-23 11:45:47 CEST" ))
40- stopifnot(identical(as.character(git_t , tz = " Europe/Stockholm" , origin = " 1980-02-02" , usetz = FALSE ),
43+ stopifnot(identical(as.character(git_t , tz = " Europe/Stockholm" ,
44+ origin = " 1980-02-02" , usetz = FALSE ),
4145 " 2024-04-23 11:45:47" ))
4246
4347# # Test that origin/tz can be passed to print
4448stopifnot(identical(
45- utils :: capture.output(print(git_t , tz = " Europe/Stockholm" , origin = " 1980-02-02" )),
49+ utils :: capture.output(print(git_t , tz = " Europe/Stockholm" ,
50+ origin = " 1980-02-02" )),
4651 " 2024-04-23 11:45:47 CEST"
4752))
4853stopifnot(identical(
49- utils :: capture.output(print(git_t , tz = " Europe/Stockholm" , origin = " 1980-02-02" , usetz = FALSE )),
54+ utils :: capture.output(print(git_t , tz = " Europe/Stockholm" ,
55+ origin = " 1980-02-02" , usetz = FALSE )),
5056 " 2024-04-23 11:45:47"
5157))
0 commit comments