Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automation 3.0.2 - preview #4308

Merged
merged 8 commits into from
May 14, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add syncJob updated properties, syncJobStreams, webhook test recording
  • Loading branch information
Maria Romero committed May 10, 2018

Verified

This commit was signed with the committer’s verified signature.
dagar Daniel Agar
commit fd5bfb1e178eb22123780d00fd138148731ba88e
Original file line number Diff line number Diff line change
@@ -16,7 +16,7 @@ namespace Automation.Tests.ScenarioTests

public class AutomationTest
{
[Fact]
//[Fact]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mark as a skipped tests instead of commenting

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

public void CanCreateUpdateDeleteRunbook()
{
using (var context = MockContext.Start(GetType().FullName))
@@ -269,7 +269,7 @@ public void CanCreateUpdateDeleteDscConfiguration()
}
}

[Fact]
//[Fact]
public void CanCreateUpdateDeleteDscNodeConfiguration()
{
using (var context = MockContext.Start(GetType().FullName))
@@ -429,7 +429,7 @@ public void CanCreateUpdateDeleteSourceControl()
}
}

[Fact]
//[Fact]
public void CanCreateSourceControlSyncJob()
{
using (var context = MockContext.Start(GetType().FullName))
@@ -459,19 +459,19 @@ public void CanCreateSourceControlSyncJob()
var retrievedSyncJob = testFixture.GetSourceControlSyncJob(sourceControlName, syncJobId);

Assert.NotNull(retrievedSyncJob);
Assert.Equal(retrievedSyncJob.SourceControlSyncJobId, syncJobId.ToString());
Assert.Equal(retrievedSyncJob.SyncJobId, syncJobId.ToString());
Assert.Equal(retrievedSyncJob.CreationTime, syncJob.CreationTime);
Assert.Equal(retrievedSyncJob.ProvisioningState, syncJob.ProvisioningState);
Assert.Equal(retrievedSyncJob.StartTime, syncJob.StartTime);
Assert.Equal(retrievedSyncJob.EndTime, syncJob.EndTime);
Assert.Equal(retrievedSyncJob.StartedBy, syncJob.StartedBy);
Assert.Equal(retrievedSyncJob.StartType, syncJob.StartType);

var syncJobList = testFixture.GetSourceControlSyncJobs(sourceControlName);

Assert.NotNull(syncJobList);
Assert.Single(syncJobList.ToList());
syncJob = syncJobList.ToList()[0];
Assert.Equal(syncJob.SourceControlSyncJobId, syncJob.SourceControlSyncJobId);
Assert.Equal(syncJob.SyncJobId, syncJob.SyncJobId);
}
}
}

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -35,28 +35,28 @@ public SourceControlSyncJob()
/// <param name="name">Resource name.</param>
/// <param name="type">Resource type.</param>
/// <param name="id">Resource id.</param>
/// <param name="sourceControlSyncJobId">Gets the source control sync
/// job id.</param>
/// <param name="syncJobId">Gets the source control sync job
/// id.</param>
/// <param name="creationTime">Gets the creation time of the
/// job.</param>
/// <param name="provisioningState">Gets the provisioning state of the
/// job. Possible values include: 'Completed', 'Failed',
/// 'Running'</param>
/// <param name="startTime">Gets the start time of the job.</param>
/// <param name="endTime">Gets the end time of the job.</param>
/// <param name="startedBy">Gets the user who started the sync
/// job.</param>
public SourceControlSyncJob(string name = default(string), string type = default(string), string id = default(string), string sourceControlSyncJobId = default(string), System.DateTimeOffset creationTime = default(System.DateTimeOffset), string provisioningState = default(string), System.DateTimeOffset? startTime = default(System.DateTimeOffset?), System.DateTimeOffset? endTime = default(System.DateTimeOffset?), string startedBy = default(string))
/// <param name="startType">Gets the type of start for the sync job.
/// Possible values include: 'AutoSync', 'ManualSync'</param>
public SourceControlSyncJob(string name = default(string), string type = default(string), string id = default(string), string syncJobId = default(string), System.DateTimeOffset creationTime = default(System.DateTimeOffset), string provisioningState = default(string), System.DateTimeOffset? startTime = default(System.DateTimeOffset?), System.DateTimeOffset? endTime = default(System.DateTimeOffset?), string startType = default(string))
{
Name = name;
Type = type;
Id = id;
SourceControlSyncJobId = sourceControlSyncJobId;
SyncJobId = syncJobId;
CreationTime = creationTime;
ProvisioningState = provisioningState;
StartTime = startTime;
EndTime = endTime;
StartedBy = startedBy;
StartType = startType;
CustomInit();
}

@@ -86,8 +86,8 @@ public SourceControlSyncJob()
/// <summary>
/// Gets the source control sync job id.
/// </summary>
[JsonProperty(PropertyName = "properties.sourceControlSyncJobId")]
public string SourceControlSyncJobId { get; set; }
[JsonProperty(PropertyName = "properties.syncJobId")]
public string SyncJobId { get; set; }

/// <summary>
/// Gets the creation time of the job.
@@ -115,10 +115,11 @@ public SourceControlSyncJob()
public System.DateTimeOffset? EndTime { get; private set; }

/// <summary>
/// Gets the user who started the sync job.
/// Gets the type of start for the sync job. Possible values include:
/// 'AutoSync', 'ManualSync'
/// </summary>
[JsonProperty(PropertyName = "properties.startedBy")]
public string StartedBy { get; set; }
[JsonProperty(PropertyName = "properties.startType")]
public string StartType { get; set; }

}
}
Original file line number Diff line number Diff line change
@@ -33,29 +33,29 @@ public SourceControlSyncJobById()
/// Initializes a new instance of the SourceControlSyncJobById class.
/// </summary>
/// <param name="id">Gets the id of the job.</param>
/// <param name="sourceControlSyncJobId">Gets the source control sync
/// job id.</param>
/// <param name="syncJobId">Gets the source control sync job
/// id.</param>
/// <param name="creationTime">Gets the creation time of the
/// job.</param>
/// <param name="provisioningState">Gets the provisioning state of the
/// job. Possible values include: 'Completed', 'Failed',
/// 'Running'</param>
/// <param name="startTime">Gets the start time of the job.</param>
/// <param name="endTime">Gets the end time of the job.</param>
/// <param name="startedBy">Gets the user who started the sync
/// job.</param>
/// <param name="errors">Error details of the source control sync
/// job.</param>
public SourceControlSyncJobById(string id = default(string), string sourceControlSyncJobId = default(string), System.DateTimeOffset creationTime = default(System.DateTimeOffset), string provisioningState = default(string), System.DateTimeOffset? startTime = default(System.DateTimeOffset?), System.DateTimeOffset? endTime = default(System.DateTimeOffset?), string startedBy = default(string), SourceControlSyncJobByIdErrors errors = default(SourceControlSyncJobByIdErrors))
/// <param name="startType">Gets the type of start for the sync job.
/// Possible values include: 'AutoSync', 'ManualSync'</param>
/// <param name="exception">Gets the exceptions that occured while
/// running the sync job.</param>
public SourceControlSyncJobById(string id = default(string), string syncJobId = default(string), System.DateTimeOffset creationTime = default(System.DateTimeOffset), string provisioningState = default(string), System.DateTimeOffset? startTime = default(System.DateTimeOffset?), System.DateTimeOffset? endTime = default(System.DateTimeOffset?), string startType = default(string), string exception = default(string))
{
Id = id;
SourceControlSyncJobId = sourceControlSyncJobId;
SyncJobId = syncJobId;
CreationTime = creationTime;
ProvisioningState = provisioningState;
StartTime = startTime;
EndTime = endTime;
StartedBy = startedBy;
Errors = errors;
StartType = startType;
Exception = exception;
CustomInit();
}

@@ -73,8 +73,8 @@ public SourceControlSyncJobById()
/// <summary>
/// Gets the source control sync job id.
/// </summary>
[JsonProperty(PropertyName = "properties.sourceControlSyncJobId")]
public string SourceControlSyncJobId { get; set; }
[JsonProperty(PropertyName = "properties.syncJobId")]
public string SyncJobId { get; set; }

/// <summary>
/// Gets the creation time of the job.
@@ -102,16 +102,17 @@ public SourceControlSyncJobById()
public System.DateTimeOffset? EndTime { get; private set; }

/// <summary>
/// Gets the user who started the sync job.
/// Gets the type of start for the sync job. Possible values include:
/// 'AutoSync', 'ManualSync'
/// </summary>
[JsonProperty(PropertyName = "properties.startedBy")]
public string StartedBy { get; set; }
[JsonProperty(PropertyName = "properties.startType")]
public string StartType { get; set; }

/// <summary>
/// Gets or sets error details of the source control sync job.
/// Gets the exceptions that occured while running the sync job.
/// </summary>
[JsonProperty(PropertyName = "properties.errors")]
public SourceControlSyncJobByIdErrors Errors { get; set; }
[JsonProperty(PropertyName = "properties.exception")]
public string Exception { get; set; }

}
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.Automation.Models
{
using Microsoft.Rest;
using Microsoft.Rest.Serialization;
using Newtonsoft.Json;
using System.Linq;

/// <summary>
/// Definition of the source control sync job stream.
/// </summary>
[Rest.Serialization.JsonTransformation]
public partial class SourceControlSyncJobStream
{
/// <summary>
/// Initializes a new instance of the SourceControlSyncJobStream class.
/// </summary>
public SourceControlSyncJobStream()
{
CustomInit();
}

/// <summary>
/// Initializes a new instance of the SourceControlSyncJobStream class.
/// </summary>
/// <param name="id">Resource id.</param>
/// <param name="syncJobStreamId">Gets the sync job stream id.</param>
/// <param name="summary">Gets the summary of the sync job
/// stream.</param>
/// <param name="time">Gets the time of the sync job stream.</param>
/// <param name="streamType">Gets the type of the sync job stream.
/// Possible values include: 'Error', 'Output'</param>
public SourceControlSyncJobStream(string id = default(string), string syncJobStreamId = default(string), string summary = default(string), System.DateTimeOffset? time = default(System.DateTimeOffset?), string streamType = default(string))
{
Id = id;
SyncJobStreamId = syncJobStreamId;
Summary = summary;
Time = time;
StreamType = streamType;
CustomInit();
}

/// <summary>
/// An initialization method that performs custom operations like setting defaults
/// </summary>
partial void CustomInit();

/// <summary>
/// Gets resource id.
/// </summary>
[JsonProperty(PropertyName = "id")]
public string Id { get; private set; }

/// <summary>
/// Gets the sync job stream id.
/// </summary>
[JsonProperty(PropertyName = "properties.syncJobStreamId")]
public string SyncJobStreamId { get; set; }

/// <summary>
/// Gets the summary of the sync job stream.
/// </summary>
[JsonProperty(PropertyName = "properties.summary")]
public string Summary { get; set; }

/// <summary>
/// Gets the time of the sync job stream.
/// </summary>
[JsonProperty(PropertyName = "properties.time")]
public System.DateTimeOffset? Time { get; private set; }

/// <summary>
/// Gets the type of the sync job stream. Possible values include:
/// 'Error', 'Output'
/// </summary>
[JsonProperty(PropertyName = "properties.streamType")]
public string StreamType { get; set; }

}
}
Loading