Skip to content

Commit

Permalink
(#2) test passing++
Browse files Browse the repository at this point in the history
  • Loading branch information
henricasanova committed Oct 10, 2019
1 parent ee67c05 commit 09a5d44
Showing 1 changed file with 33 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,33 +47,55 @@ class VirtualizedClusterServiceResourceAllocationTest : public ::testing::Test {
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/\"/>"
" </disk>"
" <disk id=\"scratch_disk\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <disk id=\"scratch_disk1\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch\"/>"
" <prop id=\"mount\" value=\"/scratch1\"/>"
" </disk>"
" <disk id=\"scratch_disk2\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch2\"/>"
" </disk>"
" <disk id=\"scratch_disk3\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch3\"/>"
" </disk>"
" </host> "
" <host id=\"4Cores10RAM\" speed=\"1f\" core=\"4\"> "
" <disk id=\"large_disk\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/\"/>"
" </disk>"
" <disk id=\"scratch_disk\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <disk id=\"scratch_disk1\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch\"/>"
" <prop id=\"mount\" value=\"/scratch1\"/>"
" </disk>"
" <disk id=\"scratch_disk2\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch2\"/>"
" </disk>"
" <disk id=\"scratch_disk3\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch3\"/>"
" </disk>"
" </host> "
" <prop id=\"ram\" value=\"10B\"/> "
" </host> "
" <host id=\"2Cores20RAM\" speed=\"1f\" core=\"2\"> "
" <disk id=\"large_disk\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/\"/>"
" </disk>"
" <disk id=\"scratch_disk\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <disk id=\"scratch_disk1\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch\"/>"
" <prop id=\"mount\" value=\"/scratch1\"/>"
" </disk>"
" <disk id=\"scratch_disk2\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch2\"/>"
" </disk>"
" <disk id=\"scratch_disk3\" read_bw=\"100MBps\" write_bw=\"40MBps\">"
" <prop id=\"size\" value=\"100B\"/>"
" <prop id=\"mount\" value=\"/scratch3\"/>"
" </disk>"
" </host> "
" <prop id=\"ram\" value=\"20B\"/> "
" </host> "
" <link id=\"1\" bandwidth=\"5000GBps\" latency=\"0us\"/>"
Expand Down Expand Up @@ -211,19 +233,19 @@ void VirtualizedClusterServiceResourceAllocationTest::do_VMResourceAllocationAlg
cloud_service_first_fit = simulation->add(
new wrench::CloudComputeService(hostname,
compute_hosts,
{"/scratch"},
{"/scratch1"},
{{wrench::CloudComputeServiceProperty::VM_RESOURCE_ALLOCATION_ALGORITHM, "first-fit"}}));

cloud_service_best_fit_ram_first = simulation->add(
new wrench::CloudComputeService(hostname,
compute_hosts,
{"/scratch"},
{"/scratch2"},
{{wrench::CloudComputeServiceProperty::VM_RESOURCE_ALLOCATION_ALGORITHM, "best-fit-ram-first"}}));

cloud_service_best_fit_cores_first = simulation->add(
new wrench::CloudComputeService(hostname,
compute_hosts,
{"/scratch"},
{"/scratch3"},
{{wrench::CloudComputeServiceProperty::VM_RESOURCE_ALLOCATION_ALGORITHM, "best-fit-cores-first"}}));

// Create a WMS
Expand Down

0 comments on commit 09a5d44

Please sign in to comment.