(c *LocalCluster)
| 456 | } |
| 457 | |
| 458 | func mountBinary(c *LocalCluster) (mount.Mount, error) { |
| 459 | // We shouldn't need to call setupBinary here, we already call it in LocalCluster.setupBeforeCluster |
| 460 | // function which is called whenever the dgraph's cluster version is initialized or upgraded. Though, |
| 461 | // we have observed "exec format error" when we don't do this. Our suspicion is that this is related |
| 462 | // to the fact that we mount same binary inside multiple docker containers. We noticed a similar |
| 463 | // issue with this PR when we mount same ACL secret file inside multiple containers. |
| 464 | if err := c.setupBinary(); err != nil { |
| 465 | return mount.Mount{}, err |
| 466 | } |
| 467 | |
| 468 | return mount.Mount{ |
| 469 | Type: mount.TypeBind, |
| 470 | Source: c.tempBinDir, |
| 471 | Target: goBinMountPath, |
| 472 | ReadOnly: true, |
| 473 | }, nil |
| 474 | } |
| 475 | |
| 476 | // ShouldSkipTest skips a given test if clusterVersion < minVersion |
| 477 | func ShouldSkipTest(t *testing.T, minVersion, clusterVersion string) { |
no test coverage detected