package Ġf tl . gc Ċ Ċ import Ġcom . google . api . services . testing . model . Tool Results History Ċ import Ġcom . google . common . truth . Truth . assertThat Ċ import Ġf tl . args . Android Args Ċ import Ġf tl . test . util . Fl ank TestRunner Ċ import Ġorg . junit . Test Ċ import Ġorg . junit . runner . RunWith Ċ import Ġorg . mockito . Mockito .` when ` Ċ import Ġorg . mockito . Mockito . mock Ċ Ċ @ RunWith ( Fl ank TestRunner :: class ) Ċ class ĠG c Tool Results Test Ġ{ ĊĊĠĠĠ Ġ@ Test ĊĠĠĠ Ġfun Ġ` create Tool Results History Ġnull Ġsucceeds `() Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġargs Ġ= Ġmock ( Android Args :: class . java ) ĊĠĠĠĠĠĠĠ Ġ` when `( args . project ). thenReturn (" 1 2 3 ") ĊĊĠĠĠĠĠĠĠ Ġval Ġexpected Ġ= ĠTool Results History (). set ProjectId (" 1 2 3 ") ĊĊĠĠĠĠĠĠĠ ĠassertThat ( Gc Tool Results . create Tool Results History ( args )). isEqualTo ( expected ) ĊĠĠĠ Ġ} ĊĊĠĠĠ Ġ@ Test ĊĠĠĠ Ġfun Ġ` create Tool Results History Ġsucceeds `() Ġ{ ĊĠĠĠĠĠĠĠ Ġval Ġargs Ġ= Ġmock ( Android Args :: class . java ) ĊĠĠĠĠĠĠĠ Ġ` when `( args . project ). thenReturn (" 1 2 3 ") ĊĠĠĠĠĠĠĠ Ġ` when `( args . results History Name ). thenReturn (" custom Ġhistory ") ĊĊĠĠĠĠĠĠĠ Ġval Ġexpected Ġ= ĠTool Results History () ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. set ProjectId (" 1 2 3 ") ĊĠĠĠĠĠĠĠĠĠĠĠ Ġ. set History Id (" mock Id ") ĊĊĠĠĠĠĠĠĠ ĠassertThat ( Gc Tool Results . create Tool Results History ( args )). isEqualTo ( expected ) ĊĠĠĠ Ġ} Ċ } Ċ