mirror of
https://github.com/google/nomulus.git
synced 2025-06-27 14:54:51 +02:00
Rename all testdata loading files to conform to a single naming scheme
The scheme is: - loadBytes: returns a ByteSource of the data - loadFile: returns a string using UTF8 encoding, optionally applying substitutions ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=177606406
This commit is contained in:
parent
ebfa27b3ad
commit
b8970bfe1b
94 changed files with 428 additions and 449 deletions
|
@ -16,7 +16,7 @@ package google.registry.flows;
|
|||
|
||||
import static com.google.common.truth.Truth.assertThat;
|
||||
import static com.google.common.truth.Truth8.assertThat;
|
||||
import static google.registry.testing.TestDataHelper.loadFileWithSubstitutions;
|
||||
import static google.registry.testing.TestDataHelper.loadFile;
|
||||
import static google.registry.testing.TestLogHandlerUtils.findFirstLogMessageByPrefix;
|
||||
import static java.nio.charset.StandardCharsets.UTF_8;
|
||||
import static org.mockito.Mockito.mock;
|
||||
|
@ -26,7 +26,6 @@ import static org.mockito.Mockito.verify;
|
|||
import com.google.appengine.api.users.User;
|
||||
import com.google.common.base.Joiner;
|
||||
import com.google.common.base.Splitter;
|
||||
import com.google.common.collect.ImmutableMap;
|
||||
import com.google.common.collect.ImmutableSet;
|
||||
import com.google.common.testing.TestLogHandler;
|
||||
import google.registry.model.eppcommon.Trid;
|
||||
|
@ -180,8 +179,7 @@ public class FlowRunnerTest extends ShardableTestCase {
|
|||
|
||||
@Test
|
||||
public void testRun_legacyLoggingStatement_complexEppInput() throws Exception {
|
||||
String domainCreateXml = loadFileWithSubstitutions(
|
||||
getClass(), "domain_create_prettyprinted.xml", ImmutableMap.<String, String>of());
|
||||
String domainCreateXml = loadFile(getClass(), "domain_create_prettyprinted.xml");
|
||||
flowRunner.inputXmlBytes = domainCreateXml.getBytes(UTF_8);
|
||||
flowRunner.run(eppMetricBuilder);
|
||||
String logMessage = findFirstLogMessageByPrefix(handler, "EPP Command\n\t");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue