Skip to content

Commit

Permalink
Merge pull request #851 from remind101/created-at
Browse files Browse the repository at this point in the history
Don't set EMPIRE_CREATED_AT env var.
  • Loading branch information
ejholmes committed May 24, 2016
2 parents 1d0e5ed + dfd7798 commit 1a66aea
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 22 deletions.
1 change: 0 additions & 1 deletion releases.go
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,6 @@ func newSchedulerApp(release *Release) *scheduler.App {
env["EMPIRE_APPID"] = release.App.ID
env["EMPIRE_APPNAME"] = release.App.Name
env["EMPIRE_RELEASE"] = fmt.Sprintf("v%d", release.Version)
env["EMPIRE_CREATED_AT"] = timex.Now().Format(time.RFC3339)

labels := map[string]string{
"empire.app.id": release.App.ID,
Expand Down
37 changes: 16 additions & 21 deletions tests/empire/empire_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,10 +101,9 @@ func TestEmpire_Deploy(t *testing.T) {
ID: app.ID,
Name: "acme-inc",
Env: map[string]string{
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
"EMPIRE_CREATED_AT": "2015-01-01T01:01:01Z",
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
},
Labels: map[string]string{
"empire.app.name": "acme-inc",
Expand Down Expand Up @@ -266,10 +265,9 @@ func TestEmpire_Run(t *testing.T) {
ID: app.ID,
Name: "acme-inc",
Env: map[string]string{
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
"EMPIRE_CREATED_AT": "2015-01-01T01:01:01Z",
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
},
Labels: map[string]string{
"empire.app.name": "acme-inc",
Expand Down Expand Up @@ -340,10 +338,9 @@ func TestEmpire_Run_WithConstraints(t *testing.T) {
ID: app.ID,
Name: "acme-inc",
Env: map[string]string{
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
"EMPIRE_CREATED_AT": "2015-01-01T01:01:01Z",
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
},
Labels: map[string]string{
"empire.app.name": "acme-inc",
Expand Down Expand Up @@ -421,11 +418,10 @@ func TestEmpire_Set(t *testing.T) {
ID: app.ID,
Name: "acme-inc",
Env: map[string]string{
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
"EMPIRE_CREATED_AT": "2015-01-01T01:01:01Z",
"RAILS_ENV": "production",
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v1",
"RAILS_ENV": "production",
},
Labels: map[string]string{
"empire.app.name": "acme-inc",
Expand Down Expand Up @@ -468,10 +464,9 @@ func TestEmpire_Set(t *testing.T) {
ID: app.ID,
Name: "acme-inc",
Env: map[string]string{
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v2",
"EMPIRE_CREATED_AT": "2015-01-01T01:01:01Z",
"EMPIRE_APPID": app.ID,
"EMPIRE_APPNAME": "acme-inc",
"EMPIRE_RELEASE": "v2",
},
Labels: map[string]string{
"empire.app.name": "acme-inc",
Expand Down

0 comments on commit 1a66aea

Please sign in to comment.